Skip to content

Commit

Permalink
Add support for the new craft blueprint options relating to override …
Browse files Browse the repository at this point in the history
…server urls

Signed-off-by: Claudio Cambra <[email protected]>
  • Loading branch information
claucambra committed Sep 19, 2024
1 parent 278ccb8 commit 630f868
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions admin/osx/mac-crafter/Sources/main.swift
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ struct Build: ParsableCommand {
@Option(name: [.long], help: "Git clone command; include options such as depth.")
var gitCloneCommand = "git clone --depth=1"

@Option(name: [.long], help: "Override server url.")
var overrideServerUrl: String?

@Flag(help: "Reconfigure KDE Craft.")
var reconfigureCraft = false

Expand All @@ -86,6 +89,9 @@ struct Build: ParsableCommand {
@Flag(help: "Run a full rebuild.")
var fullRebuild = false

@Flag(help: "Force override server URL.")
var forceOverrideServerUrl = false

mutating func run() throws {
print("Configuring build tooling.")

Expand Down Expand Up @@ -150,6 +156,11 @@ struct Build: ParsableCommand {
"\(craftBlueprintName).buildFileProviderModule=\(buildFileProviderModule ? "True" : "False")"
]

if let overrideServerUrl {
craftOptions.append("\(craftBlueprintName).overrideServerUrl=\(overrideServerUrl)")
craftOptions.append("\(craftBlueprintName).forceOverrideServerUrl=\(forceOverrideServerUrl ? "True" : "False")")
}

if !disableAutoUpdater {
print("Configuring Sparkle auto-updater.")

Expand Down

0 comments on commit 630f868

Please sign in to comment.