This is the mail archive of the
cygwin@cygwin.com
mailing list for the Cygwin project.
Re: script-name won't execute but script-name.py will
- From: JROZYCKI at ebmail dot gdeb dot com
- To: John Peacock <jpeacock at rowman dot com>
- Cc: Pavel Tsekov <ptsekov at syntrex dot com>, cygwin at cygwin dot com
- Date: Fri, 16 Nov 2001 10:35:03 -0500
- Subject: Re: script-name won't execute but script-name.py will
John,
Thanks for the insight. I was hoping I *could* add arbitrary extensions. Like
the .bat and .exe I thought maybe I could setup .py, .pl, .awk extensions to be
automatically recognized. I'll either have to setup aliases in my .bashrc to
the file or just type the full command_name with extension (yes my paths are
all set) because when I edit a script in Textpad without an extension I lose
syntax highlighting.
Thanks everyone for all your help.
-Jeff
John Peacock <jpeacock@rowman.com> on 11/16/2001 09:51:03 AM
To: Jeff Rozycki/EB/GDYN@GDYN
cc: Pavel Tsekov <ptsekov@syntrex.com>, cygwin@cygwin.com
Subject: Re: script-name won't execute but script-name.py will
JROZYCKI@ebmail.gdeb.com wrote:
>
> Pavel,
> We are on NT 4.0. I believe I have proper permissions because I can run the
> script when I tack on the script's extension, such as pl or awk. The response
> is "command not found", not permission denied... Here is some output:
>
> bin $ pwd
> /home/jrozycki/bin
> bin $ ll
> total 51
> drwxr-xr-x 5 jrozycki users 4096 Nov 15 19:09 ./
> drwxr-xr-x 10 jrozycki users 8192 Nov 15 15:55 ../
> -rwxr-xr-x 1 jrozycki users 735 Nov 15 14:41 maxcom.py*
> <snip>
> bin $ maxcom
> bash: maxcom: command not found
> bin $ ./maxcom
> bash: ./maxcom: No such file or directory
>
The script's name is 'maxcom.py' not 'maxcom' so why would you expect CygWin
to find it? EXE, BAT, CMD are special cases, in that you don't need to type
the extension. There is no way to do that for arbitrary extensions either in
CygWin, Windows, or any *nix I am aware of.
Rename the file to 'maxcom' and it will work (but only as ./maxcom unless you
add '.' to your path).
HTH
John
--
John Peacock
Director of Information Research and Technology
Rowman & Littlefield Publishing Group
4720 Boston Way
Lanham, MD 20706
301-459-3366 x.5010
fax 301-429-5747
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/