|
1 |
| -name "pitchfork" |
2 |
| -bin "pitchfork" |
| 1 | +name pitchfork |
| 2 | +bin pitchfork |
3 | 3 | version "0.1.5"
|
4 | 4 | about "Daemons with DX"
|
5 | 5 | usage "Usage: pitchfork <COMMAND>"
|
6 |
| -cmd "activate" help="Activate pitchfork in your shell session" { |
7 |
| - long_help r"Activate pitchfork in your shell session |
8 |
| -
|
9 |
| -Necessary for autostart/stop when entering/exiting projects with pitchfork.toml files" |
10 |
| - arg "<SHELL>" help="The shell to generate source for" |
| 6 | +cmd activate help="Activate pitchfork in your shell session" { |
| 7 | + long_help "Activate pitchfork in your shell session\n\nNecessary for autostart/stop when entering/exiting projects with pitchfork.toml files" |
| 8 | + arg <SHELL> help="The shell to generate source for" |
11 | 9 | }
|
12 |
| -cmd "cd" hide=true { |
13 |
| - flag "--shell-pid" required=true { |
14 |
| - arg "<SHELL_PID>" |
| 10 | +cmd cd hide=#true { |
| 11 | + flag --shell-pid required=#true { |
| 12 | + arg <SHELL_PID> |
15 | 13 | }
|
16 | 14 | }
|
17 |
| -cmd "clean" help="Removes stopped/failed daemons from `pitchfork list`" { |
18 |
| - alias "c" |
19 |
| -} |
20 |
| -cmd "config" help="manage/edit pitchfork.toml files" { |
21 |
| - alias "cfg" |
22 |
| - long_help r"manage/edit pitchfork.toml files |
23 |
| -
|
24 |
| -without a subcommand, lists all pitchfork.toml files from the current directory" |
25 |
| - cmd "add" help="Add a new daemon to ./pitchfork.toml" { |
26 |
| - alias "a" |
27 |
| - flag "--autostart" help="Autostart the daemon when entering the directory" |
28 |
| - flag "--autostop" help="Autostop the daemon when leaving the directory" |
29 |
| - arg "<ID>" help="ID of the daemon to add" |
30 |
| - arg "[ARGS]..." help="Arguments to pass to the daemon" var=true |
| 15 | +cmd clean help="Removes stopped/failed daemons from `pitchfork list`" { |
| 16 | + alias c |
| 17 | +} |
| 18 | +cmd config help="manage/edit pitchfork.toml files" { |
| 19 | + alias cfg |
| 20 | + long_help "manage/edit pitchfork.toml files\n\nwithout a subcommand, lists all pitchfork.toml files from the current directory" |
| 21 | + cmd add help="Add a new daemon to ./pitchfork.toml" { |
| 22 | + alias a |
| 23 | + flag --autostart help="Autostart the daemon when entering the directory" |
| 24 | + flag --autostop help="Autostop the daemon when leaving the directory" |
| 25 | + arg <ID> help="ID of the daemon to add" |
| 26 | + arg "[ARGS]..." help="Arguments to pass to the daemon" required=#false double_dash=automatic var=#true |
31 | 27 | }
|
32 |
| - cmd "remove" help="Remove a daemon from pitchfork.toml" { |
33 |
| - alias "rm" |
34 |
| - arg "<ID>" help="The ID of the daemon to remove" |
| 28 | + cmd remove help="Remove a daemon from pitchfork.toml" { |
| 29 | + alias rm |
| 30 | + arg <ID> help="The ID of the daemon to remove" |
35 | 31 | }
|
36 | 32 | }
|
37 |
| -cmd "completion" help="Generates shell completion scripts" { |
38 |
| - arg "<SHELL>" help="The shell to generate completion for" |
| 33 | +cmd completion help="Generates shell completion scripts" { |
| 34 | + arg <SHELL> help="The shell to generate completion for" |
39 | 35 | }
|
40 |
| -cmd "disable" help="Prevent a daemon from restarting" { |
41 |
| - alias "d" |
42 |
| - arg "<ID>" help="Name of the daemon to disable" |
| 36 | +cmd disable help="Prevent a daemon from restarting" { |
| 37 | + alias d |
| 38 | + arg <ID> help="Name of the daemon to disable" |
43 | 39 | }
|
44 |
| -cmd "enable" help="Allow a daemon to start" { |
45 |
| - alias "e" |
46 |
| - arg "<ID>" help="Name of the daemon to enable" |
| 40 | +cmd enable help="Allow a daemon to start" { |
| 41 | + alias e |
| 42 | + arg <ID> help="Name of the daemon to enable" |
47 | 43 | }
|
48 |
| -cmd "list" help="List all daemons" { |
49 |
| - alias "ls" |
50 |
| - flag "--hide-header" help="Show header" |
| 44 | +cmd list help="List all daemons" { |
| 45 | + alias ls |
| 46 | + flag --hide-header help="Show header" |
51 | 47 | }
|
52 |
| -cmd "logs" help="Displays logs for daemon(s)" { |
53 |
| - alias "l" |
| 48 | +cmd logs help="Displays logs for daemon(s)" { |
| 49 | + alias l |
54 | 50 | flag "-c --clear" help="Delete logs"
|
55 |
| - flag "-n" help="Show N lines of logs" { |
| 51 | + flag -n help="Show N lines of logs" { |
56 | 52 | long_help "Show N lines of logs\n\nSet to 0 to show all logs"
|
57 |
| - arg "<N>" |
| 53 | + arg <N> |
58 | 54 | }
|
59 | 55 | flag "-t --tail" help="Show logs in real-time"
|
60 |
| - arg "[ID]..." help="Show only logs for the specified daemon(s)" var=true |
| 56 | + arg "[ID]..." help="Show only logs for the specified daemon(s)" required=#false var=#true |
61 | 57 | }
|
62 |
| -cmd "run" help="Runs a one-off daemon" { |
63 |
| - alias "r" |
| 58 | +cmd run help="Runs a one-off daemon" { |
| 59 | + alias r |
64 | 60 | flag "-f --force"
|
65 |
| - arg "<ID>" help="Name of the daemon to run" |
66 |
| - arg "[RUN]..." var=true |
| 61 | + arg <ID> help="Name of the daemon to run" |
| 62 | + arg "[-- RUN]..." required=#false var=#true |
67 | 63 | }
|
68 |
| -cmd "start" help="Starts a daemon from a pitchfork.toml file" { |
69 |
| - alias "s" |
| 64 | +cmd start help="Starts a daemon from a pitchfork.toml file" { |
| 65 | + alias s |
70 | 66 | flag "-a --all" help="Start all daemons in all pitchfork.tomls"
|
71 |
| - flag "--shell-pid" hide=true { |
72 |
| - arg "<SHELL_PID>" |
| 67 | + flag --shell-pid hide=#true { |
| 68 | + arg <SHELL_PID> |
73 | 69 | }
|
74 | 70 | flag "-f --force" help="Stop the daemon if it is already running"
|
75 |
| - arg "[ID]..." help="ID of the daemon(s) in pitchfork.toml to start" var=true |
| 71 | + arg "[ID]..." help="ID of the daemon(s) in pitchfork.toml to start" required=#false var=#true |
76 | 72 | }
|
77 |
| -cmd "status" help="Display the status of a daemon" { |
78 |
| - alias "stat" |
79 |
| - arg "<ID>" |
| 73 | +cmd status help="Display the status of a daemon" { |
| 74 | + alias stat |
| 75 | + arg <ID> |
80 | 76 | }
|
81 |
| -cmd "stop" help="Sends a stop signal to a daemon" { |
82 |
| - alias "kill" |
83 |
| - arg "[ID]..." help="The name of the daemon to stop" var=true |
| 77 | +cmd stop help="Sends a stop signal to a daemon" { |
| 78 | + alias kill |
| 79 | + arg "[ID]..." help="The name of the daemon to stop" required=#false var=#true |
84 | 80 | }
|
85 |
| -cmd "supervisor" subcommand_required=true help="Start, stop, and check the status of the pitchfork supervisor daemon" { |
86 |
| - alias "sup" |
87 |
| - cmd "run" help="Runs the internal pitchfork daemon in the foreground" { |
| 81 | +cmd supervisor subcommand_required=#true help="Start, stop, and check the status of the pitchfork supervisor daemon" { |
| 82 | + alias sup |
| 83 | + cmd run help="Runs the internal pitchfork daemon in the foreground" { |
88 | 84 | flag "-f --force" help="kill existing daemon"
|
89 | 85 | }
|
90 |
| - cmd "start" help="Starts the internal pitchfork daemon in the background" { |
| 86 | + cmd start help="Starts the internal pitchfork daemon in the background" { |
91 | 87 | flag "-f --force" help="kill existing daemon"
|
92 | 88 | }
|
93 |
| - cmd "status" help="Gets the status of the pitchfork daemon" |
94 |
| - cmd "stop" help="Stops the internal pitchfork daemon running in the background" |
| 89 | + cmd status help="Gets the status of the pitchfork daemon" |
| 90 | + cmd stop help="Stops the internal pitchfork daemon running in the background" |
95 | 91 | }
|
96 |
| -cmd "usage" hide=true help="Generates a usage spec for the CLI" { |
97 |
| - long_help r"Generates a usage spec for the CLI |
98 |
| -
|
99 |
| -https://usage.jdx.dev" |
| 92 | +cmd usage hide=#true help="Generates a usage spec for the CLI" { |
| 93 | + long_help "Generates a usage spec for the CLI\n\nhttps://usage.jdx.dev" |
100 | 94 | }
|
101 |
| -cmd "wait" help="Wait for a daemon to stop, tailing the logs along the way" { |
102 |
| - alias "w" |
103 |
| - long_help r"Wait for a daemon to stop, tailing the logs along the way |
104 |
| -
|
105 |
| -Exits with the same status code as the daemon" |
106 |
| - arg "<ID>" help="The name of the daemon to wait for" |
| 95 | +cmd wait help="Wait for a daemon to stop, tailing the logs along the way" { |
| 96 | + alias w |
| 97 | + long_help "Wait for a daemon to stop, tailing the logs along the way\n\nExits with the same status code as the daemon" |
| 98 | + arg <ID> help="The name of the daemon to wait for" |
107 | 99 | }
|
108 | 100 |
|
109 | 101 | complete "id" run="pitchfork ls | awk '{print $1}'"
|
|
0 commit comments