Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!princeton!caip!seismo!brl-adm!brl-smoke!gwyn From: gwyn@brl-smoke.ARPA (Doug Gwyn ) Newsgroups: net.unix Subject: Re: gripes about /bin/sh AND /bin/csh Message-ID: <1420@brl-smoke.ARPA> Date: Tue, 17-Jun-86 12:01:00 EDT Article-I.D.: brl-smok.1420 Posted: Tue Jun 17 12:01:00 1986 Date-Received: Sat, 21-Jun-86 09:10:42 EDT References: <44@houligan.UUCP> <2027@umcp-cs.UUCP> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 14 In article <44@houligan.UUCP> dave@smaug.UUCP (Dave Cornutt) writes: -What Phil wants (me too) is some capability to open a file in a sh/csh -script and read a line at a time into a variable, like this: - open xyz - while ( ! eof(xyz) ) - read xyz $line_from_file - <...do stuff with data...> - end - close xyz -Neither sh nor has any such capability. while line_from_file=`line` do ... do stuff with $line_from_file ... done < some-file