From: mooney@dogbert.cc.ndsu.NoDak.edu (Tim Mooney)
Subject: Re: Bourne shell redirection
Date: 1996/11/23 [thread overview]
Message-ID: <578k6k$q0m@dogbert.cc.ndsu.NoDak.edu> (raw)
In-Reply-To: 19961122203200.PAA06969@ladder01.news.aol.com
[posted & cc'ed]
In article <19961122203200.PAA06969@ladder01.news.aol.com>,
<saimcplus@aol.com> wrote:
> Does anyone know of a way to redirect standard out and standard error both
> to the
> screen and to a file from a bourne shell script?
Redirect stderr onto stdout and then pipe both into `tee':
cat /etc/passwd /etc/somefilethatdoesntexist 2>&1 | tee screen-output.log
Tim
--
Tim Mooney mooney@dogbert.cc.ndsu.NoDak.edu
Information Technology Services (701) 231-1076 (Voice)
Room 242-J1, IACC Building (701) 231-8541 (Fax)
North Dakota State University, Fargo, ND 58105-5164
prev parent reply other threads:[~1996-11-23 5:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1996-11-22 5:00 Bourne shell redirection saimcplus
1996-11-23 5:00 ` Tim Mooney [this message]
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox