jacobdeichert / mask

🎭 A CLI task runner defined by a simple markdown file
MIT License
1.11k stars 55 forks source link

Example with sub-command does not work #66

Closed bligny closed 4 years ago

bligny commented 4 years ago

The "stop all" yet requires a service name:

$ mask services stop all
error: The following required arguments were not provided:
    <service_name>

USAGE:
    mask services stop [FLAGS] <service_name> [SUBCOMMAND]
$ mask services stop foo all
Stopping everything

In order to make it work, the "stop all" sub-command has to be at the same level as the "stop"

### services stop (service_name) ### services stop all

But then the help is listing them as separated (not nested) commands:

$ mask services -h
mask-services 
Commands related to starting, stopping, and restarting services

USAGE:
    mask services <SUBCOMMAND>

FLAGS:
    -h, --help    Prints help information

SUBCOMMANDS:
    help        Prints this message or the help of the given subcommand(s)
    start       Start a service.
    stop        Stop a service.
    stop all    Stop everything.
jacobdeichert commented 4 years ago

This is a documentation error.. surprised I haven't noticed it for that long.

I'll get that services stop all block removed.

jacobdeichert commented 4 years ago

Updated the readme on master to remove that block 👍