Skip to content

Commit

Permalink
Refactor how output flag works
Browse files Browse the repository at this point in the history
This changes the -o or --output flag so that it determines where the
Shortcut will output and what it will be named.
  • Loading branch information
electrikmilk committed Oct 25, 2022
1 parent 524b048 commit 1865698
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ func main() {
registerArg("share", "s", "Signing mode. [anyone, contacts] [default=contacts]")
registerArg("unsigned", "u", "Don't sign compiled Shortcut. Will NOT run on iOS or macOS.")
registerArg("debug", "d", "Save generated plist. Print debug messages and stack traces.")
registerArg("output", "o", "Path to save the shortcut. (e.g. path/to/)")
registerArg("output", "o", "Optional output file path. (e.g. /path/to/file.shortcut).")
if len(os.Args) < 2 {
usage()
os.Exit(0)
Expand Down Expand Up @@ -156,7 +156,7 @@ func sign() {
}
var outputPath = basename + ".shortcut"
if arg("output") {
outputPath = argValue("output") + outputPath
outputPath = argValue("output")
}
var signBytes, signErr = exec.Command(
"shortcuts",
Expand Down

0 comments on commit 1865698

Please sign in to comment.