Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!wuarchive!uunet!convex!usenet From: tchrist@convex.COM (Tom Christiansen) Newsgroups: comp.unix.wizards Subject: Re: How does one redirect just stderr under the C Shell? Message-ID: <1991May08.154738.26889@convex.com> Date: 8 May 91 15:47:38 GMT References: <2740@umriscc.isc.umr.edu> Sender: usenet@convex.com (news access account) Reply-To: tchrist@convex.COM (Tom Christiansen) Organization: CONVEX Software Development, Richardson, TX Lines: 32 Nntp-Posting-Host: pixel.convex.com From the keyboard of rwl@ee.umr.edu (Wayne Little): :*BUT* after all these years I still can't figure out how to redirect :*just* stderr independently of stdout under the C Shell. :I'm at a loss under the C Shell. In general, it can't be done. Now, I'm sure someone will suggest ( foo > foo.stdout ) >& foo.stderr but that's not right: stdout is mangled. Someone else will suggest ( foo > /dev/tty ) >& foo.stderr but that's not right, as stdout is no longer going where it had been going. If your system should support /dev/fd pseudo-devices, this ought to work: ( foo > /dev/stdout ) >& foo.stderr But few of us have that feature on our systems. --tom -- Tom Christiansen tchrist@convex.com convex!tchrist "So much mail, so little time."