How to create a CLI with subcommands? #558
Unanswered
real34
asked this question in
Help needed
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I have developed a bunch of scripts that sits in local folders on my machine:
For now I always use them as
~/bin/generic.mjs
or~/bin/topic/foo.mjs
.I wanted to know what would be the recommended way to group everything related to a specific topic under a single CLI entrypoint, so that I could do something like:
Are there any examples of such patterns? Is it something that
zx
wants to solve, or isn't it in its scope?Bonus: how could I then share these scripts with my coworkers? (i.e: have a shared Git repo we could pull and add to our path)
Beta Was this translation helpful? Give feedback.
All reactions