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 Reply-To: Cygwin List Message-Id: <6.1.0.6.0.20040902145655.033a0b60@pop.prospeed.net> X-Sender: Date: Thu, 02 Sep 2004 15:01:49 -0400 To: Sean Daley , cygwin AT cygwin DOT com From: Larry Hall Subject: Re: Re: Problem executing a .bat script in a directory with spaces using bash In-Reply-To: <5c8adab70409021123291886c7@mail.gmail.com> References: <5c8adab704090207557a3a359a AT mail DOT gmail DOT com> <4137566C DOT 7070203 AT sbcglobal DOT net> <5c8adab704090210405ea696e4 AT mail DOT gmail DOT com> <413760BD DOT 2080504 AT sbcglobal DOT net> <5c8adab70409021123291886c7 AT mail DOT gmail DOT com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" At 02:23 PM 9/2/2004, you wrote: >Now let's take this one step further. In the last case, it actually >thinks it wants >to execute C:\Space instead of the script. Now let's do the following: >Create a batch script called "C:\Space.bat" and put one line into it. >cat /etc/passwd. > >Now re-run the third command again: >$ /cygdrive/c/Space\ Dir/test.bat "hello world" >c:\Space Dir>cat /etc/passwd > > >This just doesn't seem right to me. But it does suggest that the whole process is causing you to loose which arguments are which. In this case, your $0 is becoming /cygdrive/c/Space. So you might try quoting your path to the script instead. I expect strace of the shell could help you see where things "go wrong" if you're looking for more insight. -- Larry Hall http://www.rfk.com RFK Partners, Inc. (508) 893-9779 - RFK Office 838 Washington Street (508) 893-9889 - FAX Holliston, MA 01746 -- 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/