From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25191 invoked by alias); 1 May 2014 22:11:54 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 25179 invoked by uid 89); 1 May 2014 22:11:53 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: Ishtar.tlinx.org Received: from ishtar.tlinx.org (HELO Ishtar.tlinx.org) (173.164.175.65) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Thu, 01 May 2014 22:11:52 +0000 Received: from [192.168.4.12] (Athenae [192.168.4.12]) by Ishtar.tlinx.org (8.14.7/8.14.4/SuSE Linux 0.8) with ESMTP id s41MBiqJ082144 for ; Thu, 1 May 2014 15:11:48 -0700 Message-ID: <5362C6A0.3040306@tlinx.org> Date: Thu, 01 May 2014 22:11:00 -0000 From: Linda Walsh User-Agent: Thunderbird MIME-Version: 1.0 To: "cygwin@cygwin.com" Subject: cygwin-bash compat/regression bug... startup line prob Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2014-05/txt/msg00022.txt.bz2 Bob McGowan wrote: > >> Because you weren't running /bin/bash at that point in time, but > >> /usr/bin/bash. Again, you snipped the relevant portion of your original > > ---- > > No...I was... the output at the top was from "t.sh", which had > > #!/bin/bash. > > > > But the error message says /usr/bin/bash. ---- That's why I commented that something was bogus. Here it is again: law.Bliss> cat /tmp/t.sh #!/bin/bash -u echo -e "Hello World\n" law.Bliss> t.sh /usr/bin/bash: - : invalid option Usage: /usr/bin/bash [GNU long option] [option] ... /usr/bin/bash [GNU long option] [option] script-file ... GNU long options: ---- The reason the above fails... (I got it to work).. is that if there is a space on the line after the "-u", that also fails. I didn't deliberately put one there, but that it no longer handles separate options is an evolution of software devolution. But NOTE -- the above error claims it is coming from /usr/bin/bash. That's not my login shell nor on the shebang line. That's cygwin-black-magic... converting all /bin paths to /usr/bin...even shells?... > > > Regarding how your script is executed: > > If you do "$ bash t.sh", the she-bang line is *ignored*, it's just a > comment in this case. --- I'm aware of that -- I was noting that the alternate ways of invoking it made a difference. Not that I didn't understand why. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple