🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.unix.shell
Article #1438

Re: How to pipe stderr to a command in Bourne or Korn shell

#1438
From: Bob McGowen x4312 dept208
Date: Mon, 08 Oct 1990 23:41
26 lines
1406 bytes
In article <6133@ge-dab.GE.COM> coleman@sunny.DAB.GE.COM (Richard Coleman) writes:
>
>-- 
>In article <1990Oct8.165133.17187@cti-software.nl>, pim@cti-software.nl (Pim Zandbergen) writes:
>|> 
>|> How can one redirect stderr to a command while leaving stdout unaffected ?
		^^^^^^^^	^^^^^^^^^^^^
>
>
>For csh and bash try       (command > temp1) >& temp2
>For sh                      command 2> temp
>
>somebody else will have to handle ksh.
>

The question was how to redirect to a command, not a file.  You might think
that something like 2| would work, but it doesn't (at least in sh, I have
no ksh to try it on).

I have tried several permutations of re-ordering file descriptors and trying
to use new ones with the _exec- builtin but have had no success yet.

Bob McGowan  (standard disclaimer, these are my own ...)
Product Support, Wyse Technology, San Jose, CA
..!uunet!wyse!bob
bob@wyse.com
Technical Details
Message-ID: <3002@wyse.wyse.com>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!seismo!dimacs.rutgers.edu!mips!wyse!bob
References: <1990Oct8.165133.17187@cti-software.nl> <6133@ge-dab.GE.COM>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!seismo!dimacs.rutgers.edu!mips!wyse!bob
From: bob@wyse.wyse.com (Bob McGowen x4312 dept208)
Newsgroups: comp.unix.shell
Subject: Re: How to pipe stderr to a command in Bourne or Korn shell
Message-ID: <3002@wyse.wyse.com>
Date: 8 Oct 90 23:41:52 GMT
References: <1990Oct8.165133.17187@cti-software.nl> <6133@ge-dab.GE.COM>
Sender: news@wyse.wyse.com
Reply-To: bob@wyse.UUCP (Bob McGowen x4312 dept208)
Organization: Wyse Technology
Lines: 26