yakshaveinc / python

Shaving Python Yaks
https://yakshaveinc.github.io/python/
The Unlicense
0 stars 0 forks source link

Command line help for humans #1

Closed techtonik closed 7 years ago

techtonik commented 7 years ago

Argparse default help for subcommands is awful. For example, previous gitless:

usage: gl.EXE [-h] [--version]
              {track,untrack,status,diff,commit,branch,tag,checkout,merge,resolve,fuse,remote,publish,switch,init,history}
              ...

Gitless: a version control system built on top of Git. More info, downloads and documentation available at http://gitless.com

optional arguments:
  -h, --help            show this help message and exit
  --version             show program's version number and exit

subcommands:
  {track,untrack,status,diff,commit,branch,tag,checkout,merge,resolve,fuse,remote,publish,switch,init,history}
    track               start tracking changes to files
    untrack             stop tracking changes to files
    status              show status of the repo
...

Help projects to get command line help for humans out of argparse: