coreutils
coreutils copied to clipboard
missing "Usage:" in true/false
it should start with Usage:
Reported here: https://bugs.launchpad.net/ubuntu/+source/rust-coreutils/+bug/2137580
$ LANG=C cargo run -q --features unix false --help|head -1
Returns false, an unsuccessful exit status.
with GNU:
LANG=C /usr/bin/false --help|head -1
Usage: /usr/bin/false [ignored command line arguments]
same for true
Hi, Should the help output order template be modified globally in src/uucore/src/lib/lib.rs or should this ordering be applied only to true and false using a custom template?
let's start with true & false first
@sylvestre, now added
relunsec@relunsec:~/software/coreutils/target/debug/Test$ ../true --help
Returns true, a successful exit status.
Immediately returns with the exit status 0, except when invoked with one of the recognized
options. In those cases it will try to write the help or version text. Any IO error during this
operation causes the program to return 1 instead.
Usage: true
Options:
--help Print help information
--version Print version information
relunsec@relunsec:~/software/coreutils/target/debug/Test$ ../false --help
Returns false, an unsuccessful exit status.
Immediately returns with the exit status 1. When invoked with one of the recognized options it
will try to write the help or version text. Any IO error during this operation is diagnosed, yet
the program will also return 1.
Usage: false
Options:
--help Print help information
--version Print version information
relunsec@relunsec:~/software/coreutils/target/debug/Test$
looks like, close that