All of lore.kernel.org
 help / color / mirror / Atom feed
From: Philip Prindeville <philipp@redfish-solutions.com>
To: Karel Zak <kzak@redhat.com>
Cc: util-linux@vger.kernel.org
Subject: Re: Adding --color option to script?
Date: Thu, 10 Mar 2011 14:18:16 -0800	[thread overview]
Message-ID: <4D794E28.4050001@redfish-solutions.com> (raw)
In-Reply-To: <20101231000329.GB17311@nb.net.home>

On 12/30/10 4:03 PM, Karel Zak wrote:
> On Thu, Dec 23, 2010 at 02:25:02PM -0800, Philip Prindeville wrote:
>> I would love to see an option like --color which used terminal
>> colors to highlight STDERR output (or, in a pinch, maybe bold it on
>> terminals that don't support color... if they still exist).
>   The script(1) command does not work on this level. It reads data
>   directly from master side of the terminal. It means that we are not
>   able to distinguish between stdout and stderr.
>
>> Sound reasonable?
>   Yes, but I don't see a way how to implement it.
>
>      Karel
>

I just realized...  it can be done by having two ptys, one for stdin/stdout, and another just for stderr.

-Philip


           reply	other threads:[~2011-03-10 22:35 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <20101231000329.GB17311@nb.net.home>]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4D794E28.4050001@redfish-solutions.com \
    --to=philipp@redfish-solutions.com \
    --cc=kzak@redhat.com \
    --cc=util-linux@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.