Signed-off-by: Claudio Cambra <claudio.cambra@nextcloud.com>
@Flag(help: "Run a full rebuild.")
var fullRebuild = false
+ @Flag(help: "Create an installer package.")
+ var package = false
+
mutating func run() throws {
print("Configuring build tooling.")
let allOptionsString = craftOptions.map({ "--options \"\($0)\"" }).joined(separator: " ")
+ let buildWorkPath = "\(buildPath)/\(craftTarget)/build"
let clientBuildDir = "\(buildPath)/\(craftTarget)/build/\(craftBlueprintName)"
if fullRebuild {
do {
}
try fm.copyItem(atPath: clientAppDir, toPath: "\(productPath)/\(appName).app")
+ if package {
+ let packagePath =
+ try buildPackage(buildWorkPath: buildWorkPath, productPath: productPath)
+ }
+
print("Done!")
}
}