From: earl_chew AT hp DOT com (Earl Chew) Subject: Re: bash -s from .bat file 16 Jul 1998 09:08:44 -0700 Message-ID: <35AD4504.FC683910.cygnus.gnu-win32@hp.com> References: <19980715164705 DOT 26747 DOT rocketmail AT send1e DOT yahoomail DOT com> Reply-To: earl AT hpato DOT aus DOT hp DOT com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: earnie_boyd AT yahoo DOT com Cc: gnu-win32 AT cygnus DOT com Earnie Boyd wrote: > > This is probably true (I haven't tried it yet), but doesn't really > > answer the question why foo.bat containing > > > > sh -s %1 < \a\b\c\foo.sh > > > > run from a Win32 command shell doesn't work on b19. > > > > It is most likely because sh which is a port of linuxes ash ends up > trying to open abcfoo.sh instead of \\a\\b\\c\\foo.sh. Sorry, I meant to write: bash -s %1 < \a\b\c\foo.sh I can understand reasons why ash doesn't work --- but I would have thought that bash would be ok. I've done some more experimenting. Here is a small shell script, c:\foo.sh: : bar=1 echo Hello I type: C:\>bash -s < \foo.sh Hello : command not found C:\>C:\tmp>bash \foo.sh Hello It turns out that I get the same behaviour if I move this to e:\foo.sh and on e: drive type: E:\vob>bash -s < \foo.sh Hello : command not found E:\vob>bash \foo.sh \foo.sh: \foo.sh: No such file or directory Note that bash is unable to find foo.sh using the drive relative Win32 path name. Earl -- >----------------------------------------------------------------------+ > Earl Chew mailto:earl_chew AT hp DOT com | > Hewlett-Packard Australia Tel: +61 3 9210 5528 | > Advanced Networks Division Fax: +61 3 9210 5550 | > 347 Burwood Highway GPS: 37 51'46"S 145 10'03"E | > Burwood East, Victoria 3151, Australia | >----------------------------------------------------------------------+ - For help on using this list (especially unsubscribing), send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".