mirror of
https://github.com/daylinmorgan/hwylterm.git
synced 2024-12-22 03:00:43 -06:00
make docs more readable
This commit is contained in:
parent
66a6deba46
commit
b0be93a7d1
1 changed files with 7 additions and 4 deletions
|
@ -19,7 +19,6 @@ type
|
||||||
valtype: string = "red"
|
valtype: string = "red"
|
||||||
args: string = "italic"
|
args: string = "italic"
|
||||||
|
|
||||||
|
|
||||||
proc helpAttr(styles: CligenStyle): Table[string, string] =
|
proc helpAttr(styles: CligenStyle): Table[string, string] =
|
||||||
{
|
{
|
||||||
"cmd" : toAnsiCode(styles.cmd),
|
"cmd" : toAnsiCode(styles.cmd),
|
||||||
|
@ -41,13 +40,17 @@ proc helpAttrOff(): Table[string,string] =
|
||||||
"args" : resetCode,
|
"args" : resetCode,
|
||||||
}.toTable()
|
}.toTable()
|
||||||
|
|
||||||
|
const
|
||||||
|
useMulti = "${doc}[bold]Usage[/]:\n $command {SUBCMD} [[sub-command options & parameters]\n\n[bold]subcommands[/]:\n$subcmds"
|
||||||
|
useHdr = "[bold]Usage[/]:\n "
|
||||||
|
use = "$command $args\n${doc}[bold]Options[/]:\n$options"
|
||||||
|
|
||||||
proc hwylCli*(
|
proc hwylCli*(
|
||||||
clcfg: var ClCfg,
|
clcfg: var ClCfg,
|
||||||
styles: CligenStyle = CligenStyle(),
|
styles: CligenStyle = CligenStyle(),
|
||||||
useMulti: string = "${doc}[bold]Usage[/]:\n $command {SUBCMD} [[sub-command options & parameters]\n\n[bold]subcommands[/]:\n$subcmds",
|
useMulti: string = useMulti,
|
||||||
useHdr: string = "[bold]usage[/]:\n ",
|
useHdr: string = useHdr,
|
||||||
use: string = "$command $args\n${doc}[bold]Options[/]:\n$options"
|
use: string = use,
|
||||||
) =
|
) =
|
||||||
|
|
||||||
if clCfg.useMulti == "":
|
if clCfg.useMulti == "":
|
||||||
|
|
Loading…
Reference in a new issue