mirror of
https://github.com/munki/munki.git
synced 2026-05-20 13:18:33 -05:00
Fix owner/group/mode options
This commit is contained in:
@@ -124,7 +124,7 @@ struct DragNDropOptions: ParsableArguments {
|
||||
help: ArgumentHelp("Alternate name for which the item should be copied as. Specifying this option also alters the corresponding 'installs' item's path with the provided name.", valueName: "name"))
|
||||
var destitemname: String? = nil
|
||||
|
||||
@Option(name: [.customShort("o"), .customLong("owner")],
|
||||
@Option(name: [.customShort("o"), .customLong("owner"), .customLong("user")],
|
||||
help: "Sets the owner of the copied item. The owner may be either a UID number or a UNIX short name. The owner will be set recursively on the item.")
|
||||
var user: String? = nil
|
||||
|
||||
|
||||
@@ -206,10 +206,10 @@ func createPkgInfoForDragNDrop(_ mountpoint: String, options: PkginfoOptions) th
|
||||
itemsToCopyItem["user"] = user
|
||||
}
|
||||
if let group = options.dmg.group {
|
||||
itemsToCopyItem["user"] = group
|
||||
itemsToCopyItem["group"] = group
|
||||
}
|
||||
if let mode = options.dmg.mode {
|
||||
itemsToCopyItem["user"] = mode
|
||||
itemsToCopyItem["mode"] = mode
|
||||
}
|
||||
info["items_to_copy"] = [itemsToCopyItem]
|
||||
info["uninstallable"] = true
|
||||
|
||||
Reference in New Issue
Block a user