Re: [PATCH] progress: use \r as EOL only if isatty(stderr) is true

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

 



Steffen Daode Nurpmeso <sdaoden@xxxxxxxxxxxxxx> writes:

> So far progress always uses \r to produce one-line output on stderr.
> This only produces useful and easy parsable output if stderr is opened
> on a file which does interpret CR as a real carriage return operation.
> This patch changes EOL to the plain newline \n control if isatty() is
> false instead.
>
> Signed-off-by: Steffen Daode Nurpmeso <sdaoden@xxxxxxxxx>

I kind of like this patch, in the sense that if there is a sane scenario
to emit progress to non-tty, we should do just LF not CRLF, but I would
like to know the real motivation behind this proposal.

I thought that we try to disable the progress pretty much everywhere when
we are not talking to a tty, so ugliness coming from many CRLF appearing
in the cron e-mail shouldn't be the issue.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]