coreutils
[Top][All Lists]
Advanced

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

Re: patch: touch --verbose


From: Michael Cook
Subject: Re: patch: touch --verbose
Date: Fri, 9 Apr 2021 16:56:30 -0400

OK, I hear you.

The counter-argument could be that the other tools cp, mv, rm, ln, chmod,
chgrp, ... have the -v option, and so it's an anomaly that touch does not.
And we should strive to avoid anomalies as best we can?

> Also xargs --verbose or (set -x; touch *) are sufficient

Those solutions show what we'd *like* to happen, what we're going to try to
make happen, but they're much more optimistic than the proposed patch at
indicating what actually happened.

Michael

On Thu, Apr 8, 2021 at 7:23 PM Bernhard Voelker <mail@bernhard-voelker.de>
wrote:

> On 4/7/21 10:11 PM, Michael Cook wrote:
> > Attached, please find a patch to add the --verbose (-v) option to the
> touch
> > command.
>
> This was already discussed:
>   https://www.gnu.org/software/coreutils/rejected_requests.html#touch
>   "
>   touch --verbose.
>   This could not be implemented robustly. Also xargs --verbose or (set -x;
> touch *) are sufficient
>   "
>
> Furthermore, the patch makes touch(1) behave differently depending on
> whether --verbose
> is given or not: 1x vs. 2x fd_reopen().  I think this is the kind of side
> effects which
> is not acceptable for a simple diagnostic option.
>
> Or to use Padraig's words from the thread referenced from above's URL:
>
>   https://lists.gnu.org/r/bug-coreutils/2012-04/msg00006.html
>   > Also to indicate as to whether files were created or not,
>   > is problematic, I don't think that can be done atomically.
>
> Have a nice day,
> Berny
>


reply via email to

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