[Top][All Lists]

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

[bug #61009] xargs need option to immediately stop on command fail

From: anonymous
Subject: [bug #61009] xargs need option to immediately stop on command fail
Date: Thu, 5 Aug 2021 05:22:48 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0

Follow-up Comment #2, bug #61009 (project findutils):

[comment #1 comment #1:]
> POSIX [1] specifies the following conditions when xargs shall terminate
> * child exits with 255,
> * child was killed by a signal, or
> * when reading the 'eofstr' string if the '-E eofstr' option is given, or
> * when regularly reaching EOF when reading from stdin.

POSIX standardize those features that are already implemented by somebody

> Still, our xargs might implement such an option as a GNU extension.

That's great!

> I would recommend a long-option like --stop-on-error for such an extension.

This would be great if we have short option in addition to long, because this
is a normal(usual) case when we want to early stop on error, i think.

> Why did you propose '-F'?  Is there any precedence in other xargs

No. This is my invention just for demonstration :-). I think about it like -F
= --fail-on-error. But -S for --stop-on-error will be good too.

> Regarding the examples - and just to be sure:
> I assume that the reproducer with 'cp' was just a simplification to
demonstrate your actual use case, right?

Yes. You are right.


Reply to this item at:


  Message sent via Savannah

reply via email to

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