nyagos
nyagos copied to clipboard
Add help option to all command !
By /?
, /help
, -help
or -h
I tried to add a help option easily. (There are some parts where the implementation is not clean, but ...)
https://github.com/zetamatta/nyagos/compare/master...tomato3713:add-build-in-cmd-help
It works in the following way.
$ pwd -h
Print the current working drive and directory.
$ pwd -help
Usage: pwd -N (N:digit) -L -P
Print the current working drive and directory.
Options:
-N: N is digit. Print the N-previous directory.
-L: Use PWD from environment, even if it contains symlinks. (default)
-P: avoid symlinks.
If this works, why not add a help option for commands other than pwd
as well?
Not a bad idea. But, Nyagos has many commands to change. It will be late to start changes.
Would you like to change commands before adding help option?