Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com From: Sam Edge To: cygwin AT cygwin DOT com Subject: Re: behaviour of "for (( exp1; exp2; exp3 )); do COMMANDS; done" Date: Tue, 27 May 2003 12:42:21 +0100 Organization: . Reply-To: cygwin AT cygwin DOT com Message-ID: References: <002901c32427$2e1553e0$78d96f83 AT pomello> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Posting-Agent: Hamster/2.0.0.1 Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id h4RBhCM18372 "Peter Oosterlynck" wrote in in gmane.os.cygwin on Tue, 27 May 2003 10:45:50 +0200: > Tried it with a Bourne shell (sh) on my Redhat AS2.1: works fine. > Tried it with a Bourne shell (sh) in cygwin : fails. The default shell on Linux is (usually) bash. More importantly /bin/sh is simply a link to /bin/bash. /bin/sh on Cygwin defaults to ash, a drop-in replacement for the Bourne Shell. /bin/sh != /bin/bash. Make sure that if your script uses Bash-specific features, it starts with #!/bin/bash and not with #!/bin/sh. That way it'll work anywhere. Regards, -- Sam Edge -- 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/