
Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [tlug] Piping stderr?
- Date: 20 Jun 2002 00:40:05 +0900
- From: "Stephen J. Turnbull" <stephen@example.com>
- Subject: Re: [tlug] Piping stderr?
- References: <3D109EC0.4070703@example.com>
- Organization: The XEmacs Project
- User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Informed Management (RC0+))
>>>>> "Josh" == Josh Glover <jmglov@example.com> writes:
Josh> Is it possible to pipe (not redirect) stderr?
Josh> Ideas?
zsh is the "Shell of the Gods". But if you won't listen to the doctor
and continue to bash yourself ;-) try
gcc --blow-chunks 2>&1 >catch-stdout | less
will give you a zero-length file named catch-stdout and "gcc: No input
files" in less.
If you want something more flexible (ie, piping both to different
places), you'll need named pipes. Alternatively you could try process
substitution, but the idiom
gcc --blow-chunks 2>(less) >catch-stdout
confuses bash pretty good.
Josh> 'foo | tee log' will handle that for stdout, but not stderr
foo 2>&1 | tee log
--
Institute of Policy and Planning Sciences http://turnbull.sk.tsukuba.ac.jp
University of Tsukuba Tennodai 1-1-1 Tsukuba 305-8573 JAPAN
My nostalgia for Icon makes me forget about any of the bad things. I don't
have much nostalgia for Perl, so its faults I remember. Scott Gilbert c.l.py
Home |
Main Index |
Thread Index