Bugs fixes, Lint fixes, Refactoring
Some checks failed
gitea-openium/resgen.swift/pipeline/head There was a failure building this commit

This commit is contained in:
2022-08-29 13:38:46 +02:00
parent e3f90e0d48
commit a54a264447
35 changed files with 652 additions and 401 deletions

View File

@@ -19,7 +19,7 @@ struct TwineOptions: ParsableArguments {
var outputPath: String
@Option(name: .customLong("langs"), help: "Langs to generate.")
var langsRaw: String
fileprivate var langsRaw: String
@Option(help: "Default langs.")
var defaultLang: String
@@ -27,3 +27,11 @@ struct TwineOptions: ParsableArguments {
@Option(help: "Path where to generate the extension.", transform: { $0.replaceTiltWithHomeDirectoryPath() })
var extensionOutputPath: String
}
extension TwineOptions {
var langs: [String] {
langsRaw
.split(separator: " ")
.map { String($0) }
}
}