delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1998/11/12/16:51:23

From: mh AT mike DOT franken DOT de (Michael Hirmke)
Subject: Re: cygwin b20 bash path usage?
12 Nov 1998 16:51:23 -0800 :
Message-ID: <74fE8wW$pfB.cygnus.gnu-win32@mike.franken.de>
References: <3647A87A DOT AE660CB7 AT ix DOT netcom DOT com>
Mime-Version: 1.0
To: gnu-win32 AT cygnus DOT com

Hi William,

>I made the mistake of creating and trying to use an exectable named
>test.exe. under bash v2.02 in the cygwin beta 20 package. Nothing
>happened when it executed. I suspect that bash was executing the program
>test.exe in the cygwin-b20\bin directory rather my test.exe in the
>directory I was using.
>
>Is this proper behavior in bash? I assumed the directory being worked in
>was searched first then along the PATH directory list.

No, this isn't the behaviour for a typical U*ix shell, but for the
Windows command prompt. In a U*ix shell comamnds in the actual directory
only get executed, if you have ".", i.e the actual directory in your PATH.
This, however, is considered a big security hole due to trojans.
Concensus seems to be to have "." in your PATH, but not as the first
directory, i.e. PATH=/foo/bar:.

>
>Bill

Bye.
Michael.
--
Michael Hirmke           | Telefon +49 (911) 557999
Georg-Strobel-Strasse 81 | FAX     +49 (911) 557664
90489 Nuernberg          | E-Mail  mailto:mh AT mike DOT franken DOT de
                         | WWW     http://aquarius.franken.de/
-
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".

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019