This is the mail archive of the
mailing list for the Cygwin project.
Changed handling of "!" in /bin/sh?
- From: Luke Kendall <luke dot kendall at cisra dot canon dot com dot au>
- To: cygwin at cygwin dot com
- Date: Tue, 16 Jan 2007 13:39:05 +1100 (EST)
- Subject: Changed handling of "!" in /bin/sh?
I have a script that starts #!/bin/sh which has occasional things like
the use of an exclamation mark in a string, or a case statement to
accept an exclamation mark to throw a shell, which has stopped working
now that I've upgraded to a non-ancient Cygwin (i.e. now that sh ==
It seems that /bin/sh is now trying to interpret "!" as bash would!
How can I make /bin/sh work like a Bourne shell, globally?
The same script works fine if run by ash instead of bash, and it also
works fine under Linux (where sh is bash), so it seems like there's
some problem with bash's emulation of sh under Cygwin.
I assume from the discussion about making sh == bash back in 2005, that
when invoked as sh it's supposed to be a drop-in replacement for sh,
Any advice? We have over 200 scripts that will need alteration,
otherwise. Any idea what I'm doing wrong?
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html