coreutils
[Top][All Lists]
Advanced

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

Re: readlink(1) of more than one file?


From: Pádraig Brady
Subject: Re: readlink(1) of more than one file?
Date: Sun, 16 Dec 2012 00:29:07 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120615 Thunderbird/13.0.1

On 12/15/2012 11:10 PM, Dmitry V. Levin wrote:
On Sat, Dec 15, 2012 at 03:40:36PM +0000, Pádraig Brady wrote:
On 12/15/2012 03:09 PM, Bernhard Voelker wrote:
[...]
And finally: -n is pretty much useless now with multiple arguments,
because the output is just concatenated together:

   $ src/readlink --no /user /user
   homehome

Wouldn't it be better to allow -n only for single-argument calls,
or use a blank " " as delimiter between the output for multiple
args, or warn?

Since -n is a largely redundant option anyway,
I was just keeping it around for compat reasons.
BSD operates like above, so why diverge?

If BSD readlink -n does something totally useless, it's not a reason
to follow and introduce that useless behaviour in GNU readlink.

I've tried to construct an example where readlink -n with multiple
arguments could be used harmlessly, and the only case I have so far
is when readlink's output does not matter (e.g. grep -q ^.) or discarded
completely.

So, please do not add multiple arguments support to readlink -n unless
you can also add a usage example for that feature.

Ok fair enough.
I'll adjust to that -n suppresses only the trailing delimiter.

thanks,
Pádraig.



reply via email to

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