This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Problem with "set," "if," "foreach" commands


Han Nguyen wrote:
> 
> New to Unix, so please have patience.
> [...]
> Anything I can do to resolve this?  I appreciate the help.  Thanks.

You seem to be entering "c shell"-type syntax at a bash shell, and it
has no idea what you're talking about.  There are many shells out there
and they all have different ideas of what valid syntax looks like.  The
default shell for Cygwin is bash.

If you want to use that form of scripting you will have to either change
your shell to csh or tcsh, or put the commands in a script and call for
the desired interpreter (i.e. make the first line #!/bin/tcsh).  To
change your shell you will want to edit cygwin.bat to call tcsh.exe (or
csh.exe or whatever) instead of bash.  If you intend to log in via rsh
or ssh you'll also want to edit your shell setting in /etc/passwd.

Brian

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]