From owner-freebsd-questions Fri Mar 22 19:44:51 2002 Delivered-To: freebsd-questions@freebsd.org Received: from post-20.mail.nl.demon.net (post-20.mail.nl.demon.net [194.159.73.1]) by hub.freebsd.org (Postfix) with ESMTP id 5722D37B422 for ; Fri, 22 Mar 2002 19:44:34 -0800 (PST) Received: from [212.238.194.207] (helo=mailhost.raggedclown.net) by post-20.mail.nl.demon.net with esmtp (Exim 3.35 #2) id 16ocSG-000BM5-00 for freebsd-questions@freebsd.org; Sat, 23 Mar 2002 03:44:33 +0000 Received: from willow.raggedclown.net (willow.raggedclown.intra [192.168.1.10]) by mailhost.raggedclown.net (Ragged Clown Mail Gateway [oz]) with ESMTP id 57AB44880D for ; Sat, 23 Mar 2002 04:44:32 +0100 (CET) Received: by willow.raggedclown.net (Ragged Clown Host [willow], from userid 1005) id AADA4225C5; Sat, 23 Mar 2002 04:44:32 +0100 (CET) Date: Sat, 23 Mar 2002 04:44:32 +0100 From: Cliff Sarginson To: freebsd-questions@freebsd.org Subject: Re: Bourne shell question: How to capture stdin and stdout from bourne shell script. Message-ID: <20020323034432.GA9544@raggedclown.net> References: <3C9BF45E.BBEB5911@nc.rr.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3C9BF45E.BBEB5911@nc.rr.com> User-Agent: Mutt/1.3.27i Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Mar 22, 2002 at 10:19:59PM -0500, Michael E Mercer wrote: > Peoples, > > How can you use Bourne shell to capture all the stdout and stdin of a shell > script? > > I have a script that asks a number of questions, and I want to capture the > questions and answers > in a file called results.log. > > How do I go about it? It would really be nice if this could be done entirely > within the script without > user intervention other than answering the questions. > > Thanks > Michael Mercer script try it out :) it records everything in a file name of your choosing type "man script" for details -- Regards Cliff Sarginson -- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message