Skip to content

Commit

Permalink
Update template to accommodate recent changes in target struct
Browse files Browse the repository at this point in the history
  • Loading branch information
SimplyDanny committed Aug 6, 2024
1 parent 5d473ba commit 22bdffe
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions tools/Version.swift.template
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
/// A type describing the SwiftLint version.
public struct Version {
public struct Version: VersionComparable {
/// The string value for this version.
public let value: String

/// An alias for `value` required for protocol conformance.
public var rawValue: String {
value
}

/// The current SwiftLint version.
public static let current = Version(value: "__VERSION__")
public static let current = Self(value: "__VERSION__")

/// Public initializer.
///
/// - parameter value: The string value for this version.
public init(value: String) {
self.value = value
}
}

0 comments on commit 22bdffe

Please sign in to comment.