This is the mail archive of the
cygwin@cygwin.com
mailing list for the Cygwin project.
Re: what does it mean in csh
- From: Randall R Schulz <rrschulz at cris dot com>
- To: "hongxun lee" <lee dot 1801 at osu dot edu>, "cygwin mailing list" <cygwin at cygwin dot com>
- Date: Tue, 08 Jan 2002 19:34:37 -0800
- Subject: Re: what does it mean in csh
Hongxun,
To a first approximation, at least, it's this:
read x
CSH's $< is a request to read a line from the current standard input
(subject to whatever redirection may be in effect, of course). In
conjunction with a "set" command, the value read becomes the value of the
named variable.
In BASH you can read multiple variables in one call. The input is parsed
respecting $IFS and if there are more parsed words in the input line than
there are variables named in the "read" command, then all the left over
words are assigned (with spaces reinserted between the parsed words) to the
last variable named in the read command.
Use BASH's built-in "help" command ("help read") for the gory details and
options.
Randall Schulz
Mountain View, CA USA
At 18:57 2002-01-08, hongxun lee wrote:
>The line below is included in a csh script (to install Ada compiler), but
>i only have bash (Cygwin) on my PC. What is its equivalent in bash? Thanks
>
>set x = $<
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/