1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 11:37:44 +00:00

sort: remove duplication from usage string

The custom usage string does not have to include the "sort\nUsage:" part,
because this part is already printed by clap.

It prevents the following duplication:

USAGE:
    sort
Usage:
 sort [OPTION]... [FILE]..

Now, only the following is printed:

USAGE:
    sort [OPTION]... [FILE]...
This commit is contained in:
Michael Debertol 2021-07-27 23:54:29 +02:00
parent 2177b8dc37
commit bd7d8fdde7

View file

@ -916,9 +916,7 @@ impl FieldSelector {
fn get_usage() -> String {
format!(
"{0}
Usage:
{0} [OPTION]... [FILE]...
"{0} [OPTION]... [FILE]...
Write the sorted concatenation of all FILE(s) to standard output.
Mandatory arguments for long options are mandatory for short options too.
With no FILE, or when FILE is -, read standard input.",