Skip to content

Commit

Permalink
Add option to not include comments in compiled Shortcut
Browse files Browse the repository at this point in the history
  • Loading branch information
electrikmilk committed Aug 3, 2023
1 parent 1d169f5 commit ce7273a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ func init() {
args.Register("output", "o", "Optional output file path. (e.g. /path/to/file.shortcut).", true)
args.Register("import", "i", "Opens compiled Shortcut after compilation. Ignored if unsigned.", false)
args.Register("auto-inc", "a", "Automatically include Cherri files in this directory.", false)
args.Register("comments", "c", "Don't include comments in the compiled Shortcut.", false)
args.Register("no-ansi", "", "Don't output ANSI escape sequences that format and color the output.", false)
args.CustomUsage = "[FILE]"
}
Expand Down
3 changes: 3 additions & 0 deletions plistgen.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,9 @@ func plistActions() {
}

func plistComment(comment string) {
if args.Using("comments") {
return
}
shortcutActions = append(shortcutActions, makeStdAction("comment", []plistData{
{
key: "WFCommentActionText",
Expand Down

0 comments on commit ce7273a

Please sign in to comment.