* Incorrect --help / manpage for -color for ip, tc, bridge
@ 2020-12-12 20:07 Witold Baryluk
2020-12-14 16:00 ` Stephen Hemminger
0 siblings, 1 reply; 2+ messages in thread
From: Witold Baryluk @ 2020-12-12 20:07 UTC (permalink / raw)
To: netdev
iproute 5.9.0
Apparently ip -c is a shortcut to ip -color
but in tc, tc -c doesn't work, one needs to say tc -col or tc -color
I understand there is tc -conf, which has tc -c.
But:
Help says:
root@debian:~# tc
Usage: tc [ OPTIONS ] OBJECT { COMMAND | help }
tc [-force] -batch filename
where OBJECT := { qdisc | class | filter | chain |
action | monitor | exec }
OPTIONS := { -V[ersion] | -s[tatistics] | -d[etails] | -r[aw] |
-o[neline] | -j[son] | -p[retty] | -c[olor]
-b[atch] [filename] | -n[etns] name | -N[umeric] |
-nm | -nam[es] | { -cf | -conf } path }
this should be:
root@debian:~# tc
Usage: tc [ OPTIONS ] OBJECT { COMMAND | help }
tc [-force] -batch filename
where OBJECT := { qdisc | class | filter | chain |
action | monitor | exec }
OPTIONS := { -V[ersion] | -s[tatistics] | -d[etails] | -r[aw] |
-o[neline] | -j[son] | -p[retty] | -col[or]
-b[atch] [filename] | -n[etns] name | -N[umeric] |
-nm | -nam[es] | { -cf | -c[onf] } path }
( -c[olor] -> -col[or] ) # also in --help for ip and bridge
If only -c meaning -conf could be removed, it would be even nicer. -cf
is already short.
Additionally in manpage for tc, ip and bridge:
-c[color][={always|auto|never}
Configure color output. If parameter is omitted or
always, color output is enabled regardless of stdout state. If
parameter is auto, stdout is checked to be a terminal be‐
fore enabling color output. If parameter is never,
color output is disabled. If specified multiple times, the last one
takes precedence. This flag is ignored if -json is
also given.
I don't think this is correct either.
Should be -col[or], not -c[color] (sic!).
Similar mistakes are in man pages and --help messages also for ip,
bridge, not just tc.
Regards,
Witold
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Incorrect --help / manpage for -color for ip, tc, bridge
2020-12-12 20:07 Incorrect --help / manpage for -color for ip, tc, bridge Witold Baryluk
@ 2020-12-14 16:00 ` Stephen Hemminger
0 siblings, 0 replies; 2+ messages in thread
From: Stephen Hemminger @ 2020-12-14 16:00 UTC (permalink / raw)
To: Witold Baryluk; +Cc: netdev
On Sat, 12 Dec 2020 20:07:16 +0000
Witold Baryluk <witold.baryluk@gmail.com> wrote:
> iproute 5.9.0
>
> Apparently ip -c is a shortcut to ip -color
>
> but in tc, tc -c doesn't work, one needs to say tc -col or tc -color
>
> I understand there is tc -conf, which has tc -c.
>
> But:
>
> Help says:
>
> root@debian:~# tc
> Usage: tc [ OPTIONS ] OBJECT { COMMAND | help }
> tc [-force] -batch filename
> where OBJECT := { qdisc | class | filter | chain |
> action | monitor | exec }
> OPTIONS := { -V[ersion] | -s[tatistics] | -d[etails] | -r[aw] |
> -o[neline] | -j[son] | -p[retty] | -c[olor]
> -b[atch] [filename] | -n[etns] name | -N[umeric] |
> -nm | -nam[es] | { -cf | -conf } path }
>
> this should be:
>
> root@debian:~# tc
> Usage: tc [ OPTIONS ] OBJECT { COMMAND | help }
> tc [-force] -batch filename
> where OBJECT := { qdisc | class | filter | chain |
> action | monitor | exec }
> OPTIONS := { -V[ersion] | -s[tatistics] | -d[etails] | -r[aw] |
> -o[neline] | -j[son] | -p[retty] | -col[or]
> -b[atch] [filename] | -n[etns] name | -N[umeric] |
> -nm | -nam[es] | { -cf | -c[onf] } path }
>
>
> ( -c[olor] -> -col[or] ) # also in --help for ip and bridge
>
> If only -c meaning -conf could be removed, it would be even nicer. -cf
> is already short.
>
> Additionally in manpage for tc, ip and bridge:
> -c[color][={always|auto|never}
> Configure color output. If parameter is omitted or
> always, color output is enabled regardless of stdout state. If
> parameter is auto, stdout is checked to be a terminal be‐
> fore enabling color output. If parameter is never,
> color output is disabled. If specified multiple times, the last one
> takes precedence. This flag is ignored if -json is
> also given.
>
>
>
> I don't think this is correct either.
>
> Should be -col[or], not -c[color] (sic!).
>
> Similar mistakes are in man pages and --help messages also for ip,
> bridge, not just tc.
>
>
> Regards,
> Witold
Send a patch to fix it.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-12-14 16:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-12 20:07 Incorrect --help / manpage for -color for ip, tc, bridge Witold Baryluk
2020-12-14 16:00 ` Stephen Hemminger
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.