replace readme help

This commit is contained in:
Daylin Morgan 2024-09-16 10:45:07 -05:00
parent 59c9fe94a5
commit d1921985b3
Signed by: daylin
GPG key ID: 950D13E9719334AD
2 changed files with 13 additions and 26 deletions

View file

@ -55,30 +55,18 @@ nix run "github:daylinmorgan/oizys"
```
nix begat oizys
Usage:
oizys [command]
oizys {SUBCMD} [sub-command options & parameters]
Available Commands:
build nix build
cache build and push to cachix
checks nix build checks
ci offload build to GHA
dry poor man's nix flake check
help Help about any command
os nixos-rebuild wrapper
output show nixosConfiguration attr
update update and run nixos rebuild
Flags:
--debug show debug output
--flake string path to flake ($OIZYS_DIR or $HOME/oizys)
-h, --help help for oizys
--host string host(s) to build (current host)
--reset-cache set narinfo-cache-negative-ttl to 0
-v, --verbose show verbose output
Use "oizys [command] --help" for more information about a command.
subcommands:
help print comprehensive or per-cmd help
build nix build
cache build and push to cachix
ci trigger GHA update flow
dry dry run build
os nixos-rebuild
output output
update update and run nixos-rebuild
```
## oizys?

View file

@ -95,10 +95,9 @@ proc setupCligen() =
let isColor = getEnv("NO_COLOR") == ""
if clCfg.useMulti == "":
clCfg.useMulti =
if isColor:
"${doc}\e[1mUsage\e[m:\n $command {SUBCMD} [sub-command options & parameters]\n\n\e[1msubcommands\e[m:\n$subcmds"
else:
"${doc}Usage:\n $command {SUBCMD} [sub-command options & parameters]\n\nsubcommands:\n$subcmds"
if isColor: "${doc}\e[1mUsage\e[m:\n $command {SUBCMD} [sub-command options & parameters]\n\n\e[1msubcommands\e[m:\n$subcmds"
else: "${doc}Usage:\n $command {SUBCMD} [sub-command options & parameters]\n\nsubcommands:\n$subcmds"
if not isColor: return
if clCfg.helpAttr.len == 0:
clCfg.helpAttr = {"cmd": "\e[1;36m", "clDescrip": "", "clDflVal": "\e[33m",