bug-coreutils
[Top][All Lists]
Advanced

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

bug#34488: Add sort --limit, or document workarounds for sort|head error


From: Assaf Gordon
Subject: bug#34488: Add sort --limit, or document workarounds for sort|head error messages
Date: Sun, 17 Feb 2019 13:31:26 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0

Hello,

On 2019-02-17 1:12 p.m., Paul Eggert wrote:
Assaf Gordon wrote:
I don't mind either way (env feature or new program).

This should be a new feature of 'nohup' not 'env', as 'nohup' is already about signal handling.  I don't see a need for a new program.

With 'nohup' I don't think there will be an easy (or at least intuitive
way) to 'untrap' SIGPIPE without affecting the output: STDOUT will be redirected to 'nohup.out' automatically (unless we add more options like "--no-redirect").

Example:

    env -C /foo/bar PROGRAM            ## only change directory
    env --default-signal=PIPE PROGRAM  ## only untrap SIGPIPE
    env -i PROGRAM                     ## only empty environment

but

    nohup --default-signal=PIPE PROGRAM

Will untrap SIGPIPE *and* SIGHUP *and* redirect stdout to a file.
So we'll need to add:

  nohup --no-redirect-stdout --default-signal=PIPE PROGRAM

Also,
nohup's manual pages warns:
   "NOTE:  your  shell  may  have  its own version of nohup, which
    usually supersedes the version described here.  Please refer to
    your shell's documentation for details about the options it
    supports."

And if there is a built-in "nohup", it will confuse users who want to
use our new feature (and then more support questions, and we have to
explain how to use "env nohup" or "\nohup".

What do you think?

-assaf









reply via email to

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