coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] chroot,comm,join: fix usage options style


From: Bernhard Voelker
Subject: Re: [PATCH] chroot,comm,join: fix usage options style
Date: Tue, 8 Dec 2020 18:12:37 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.5.0

On 12/8/20 12:49 AM, Pádraig Brady wrote:
> As it happens we're currently working on a more general solution
> to alignment of --help output, which should address this.

Yes, the idea is to output the usage texts in 3 columns: short option,
long option and description.  The question is if such automatic alignment
would lead to a nicely readable text.  The problem starts with:
- short options having arguments,
- several short options for the same thing: rm -r,-R
- several long options for the same thing: --quiet, --silent
etc.

Thus said, after fixing the above it would be hard to get better results
with automatic, columnar alignment without loosing too much space.

In that regard, the programs chroot, comm and join are just violating
the status quo: they do not align long-only options properly.
Therefore, I'm 60:40 to start with Arman's patches, yet fixing
the indentation of the description column in join and comm: see
attached (squashed) patch.

The only thing which is still a bit annoying is that the indentation
of the long option and the description via the HELP_OPTION_DESCRIPTION
and VERSION_OPTION_DESCRIPTION macros do not match that of the program.
We could address this by passing the number of necessary spaces as
parameters to the macros (and maybe change them into functions).

WDYT?

Have a nice day,
Berny

Attachment: 0001-chroot-comm-join-fix-usage-options-style.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]