mirror of
https://github.com/munki/munki.git
synced 2026-05-13 07:48:56 -05:00
Minimum viable implementation of makepkginfo: all options are ignored
This commit is contained in:
@@ -10,7 +10,6 @@ import Foundation
|
||||
|
||||
@main
|
||||
struct MakePkgInfo: ParsableCommand {
|
||||
|
||||
@OptionGroup(title: "Pkginfo Override Options")
|
||||
var overrideOptions: OverrideOptions
|
||||
|
||||
@@ -56,5 +55,15 @@ struct MakePkgInfo: ParsableCommand {
|
||||
return
|
||||
}
|
||||
|
||||
if let installerItem {
|
||||
do {
|
||||
let pkginfo = try makepkginfo(installerItem)
|
||||
let plistStr = try plistToString(pkginfo)
|
||||
print(plistStr)
|
||||
} catch {
|
||||
printStderr("Unexpected error: \(error)")
|
||||
throw ExitCode(-1)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,6 +8,8 @@
|
||||
import ArgumentParser
|
||||
import Foundation
|
||||
|
||||
// Defines option groups for makepkginfo
|
||||
// These are also used by munkiimport
|
||||
|
||||
struct OverrideOptions: ParsableArguments {
|
||||
// Pkginfo Override Options
|
||||
|
||||
Reference in New Issue
Block a user