We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5d473ba commit 22bdffeCopy full SHA for 22bdffe
tools/Version.swift.template
@@ -1,8 +1,20 @@
1
/// A type describing the SwiftLint version.
2
-public struct Version {
+public struct Version: VersionComparable {
3
/// The string value for this version.
4
public let value: String
5
6
+ /// An alias for `value` required for protocol conformance.
7
+ public var rawValue: String {
8
+ value
9
+ }
10
+
11
/// The current SwiftLint version.
- public static let current = Version(value: "__VERSION__")
12
+ public static let current = Self(value: "__VERSION__")
13
14
+ /// Public initializer.
15
+ ///
16
+ /// - parameter value: The string value for this version.
17
+ public init(value: String) {
18
+ self.value = value
19
20
}
0 commit comments