Mailing-List: contact cygwin-help@sourceware.cygnus.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@sources.redhat.com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin@sources.redhat.com>
List-Help: <mailto:cygwin-help@sources.redhat.com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner@sources.redhat.com
Delivered-To: mailing list cygwin@sources.redhat.com
Date: Sun, 12 Nov 2000 16:42:22 -0500
From: Christopher Faylor <cgf@redhat.com>
To: cygwin@cygwin.com
Subject: Re: *.COM, *.BAT must be explicitly specified to execute under bash?
Message-ID: <20001112164222.A32281@redhat.com>
Reply-To: cygwin@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
References: <4.3.1.0.20001112162810.00ad7a20@pop5.banet.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
User-Agent: Mutt/1.3.11i
In-Reply-To: <4.3.1.0.20001112162810.00ad7a20@pop5.banet.net>; from pjfarley@banet.net on Sun, Nov 12, 2000 at 04:28:14PM -0500

On Sun, Nov 12, 2000 at 04:28:14PM -0500, Peter J. Farley III wrote:
>Hi all,
>
>This is my first time on this list, and I have read (I think) all of 
>the relevant parts of the faq and user guide that apply, but I still 
>don't understand why this happens.  First let me describe the problem; 
>my system and cygwin details are at the bottom.
>
>I have several directories in my W9x PATH in which I keep useful DOS 
>commandline utilities.  Some of these are *.COM executables, some need 
>*.BAT scripts to invoke a *.COM or *.EXE module.  In both cases, it 
>seems I must specify the whole file name on the bash command line 
>(e.g., DFX.COM or ED.BAT) in order to execute these programs or 
>scripts.

If you're asking about /bin/bash or /bin/sh, then, no, they don't recognize
.com or .bat extensions, and so, you're required to specify the extension
specifically.  The Cygwin DLL treats .exe specially such that when you
do an ls -l on a .exe file you don't need to specify the .exe, i.e.,

ls -l /bin/pwd

and

ls -l /bin/pwd.exe

are equivalent.  This means that bash can find a pwd in your path and execute
pwd.exe.

Cygwin doesn't provide this for such things as .bat and .com files, since IMO,
this would slow things down for little gain.

If someone wants to provide a patch to make this configurable, however, I might
consider it.

cgf

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

