feat: Updates configuration commands and parsing strategy.
All checks were successful
CI / Ubuntu (push) Successful in 2m59s
All checks were successful
CI / Ubuntu (push) Successful in 2m59s
This commit is contained in:
@@ -36,11 +36,14 @@ extension Configuration.Branch {
|
||||
}
|
||||
|
||||
extension Configuration.SemVar {
|
||||
// TODO: Merge strategy ??
|
||||
func merging(_ other: Self?) -> Self {
|
||||
.init(
|
||||
allowPreRelease: other?.allowPreRelease ?? allowPreRelease,
|
||||
preRelease: preRelease?.merging(other?.preRelease),
|
||||
requireExistingFile: other?.requireExistingFile ?? requireExistingFile,
|
||||
requireExistingSemVar: other?.requireExistingSemVar ?? requireExistingSemVar
|
||||
requireExistingSemVar: other?.requireExistingSemVar ?? requireExistingSemVar,
|
||||
strategy: other?.strategy ?? strategy
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -175,7 +175,7 @@ public extension Configuration.SemVar {
|
||||
)
|
||||
}
|
||||
|
||||
if requireExistingFile {
|
||||
if requireExistingFile == true {
|
||||
logger.debug("Failed to parse existing file, and caller requires it.")
|
||||
throw CliClientError.fileDoesNotExist(path: file.cleanFilePath)
|
||||
}
|
||||
@@ -195,7 +195,7 @@ public extension Configuration.SemVar {
|
||||
)
|
||||
}
|
||||
|
||||
if requireExistingSemVar {
|
||||
if requireExistingSemVar == true {
|
||||
logger.trace("Caller requires existing semvar and it was not found in file or git-tag.")
|
||||
throw CliClientError.semVarNotFound
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user