delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/09/28/13:58:56

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Message-ID: <39D38664.911AAB9F@openmarket.com>
Date: Thu, 28 Sep 2000 13:56:52 -0400
From: "Guy T. Moore Jr." <gmoore AT openmarket DOT com>
Organization: Engineering
X-Mailer: Mozilla 4.73 [en] (WinNT; U)
X-Accept-Language: en
MIME-Version: 1.0
To: "Larry Hall (RFK Partners, Inc)" <lhall AT rfk DOT com>
CC: cygwin AT sourceware DOT cygnus DOT com, perakis AT openmarket DOT com,
wabraham AT openmarket DOT com
Subject: Re: bash: ./myscript: No such file or directory. TMP variableis being
unset
References: <4 DOT 3 DOT 1 DOT 2 DOT 20000928125730 DOT 0209fec0 AT pop DOT ma DOT ultranet DOT com>


"Larry Hall (RFK Partners, Inc)" wrote:
> 
> At 12:36 PM 9/28/2000, Guy T. Moore Jr. wrote:
> >1.)
> >Seems like I should be able to do the following simple shell scripting:
> >
> >
> >I'm in a Cygwin 1.1.4 window at my C: prompt.
> >
> >I create a file, called myscript,  with the 1 line of:
> >
> >      echo "doggie"
> >
> >
> >I cannot execute this successfully:
> >
> >$ ./myscript
> >bash: ./myscript: No such file or directory.
> >
> >
> >
> >I can execute myscript succesfully if I add at the top of the
> >myscript the line of:
> >
> >     #!/bin/sh
> >
> >
> >and I can also execute myscript succesfully if I, preface the command with /bin/sh:
> >
> >$ /bin/sh myscript
> >
> >
> >I'd rather get it to work the way it does on Solaris 5.7 in a bourne shell or csh
> >without using any work arounds.
> >
> >This problem is preventing other simple things from working correctly.
> 
> Your scripts aren't "portable", although that's your choice!;-)  If you
> are running on NT-based systems with NTFS file systems, you can set "ntsec"
> in your CYGWIN environment variable and then use "chmod +x <file>" (please
> read the documentation on how ntsec works though).  Alternatively, you can
> use "ntea" on NT-based systems on either NTFS or FAT drives, as long as you
> don't mind a large "EA DATA. SF" file in the root of all the FAT drives!;-)
> If you use "ntea", you can use chmod as well.  Otherwise, you need to let
> Cywgin know this is a script by adding the #!/bin/sh line or invoking it
> with the shell.  Those are your current options.


My C: drive where I am doing the test is an NTFS partition.
thus, I do have CYGWIN set properly:
CYGWIN="binmode ntea"   ( I am using ntea, cause I eventually will be trying to do this on
SAMBA-like partitions)
I have done `chmod 777 myscript`.

No luck

Can you get this to work on your PC without adding the #!/bin/sh line nor invoking it
 with the shell?


> 
> >2.)
> >I have the environment variable "TMP" defined as both a SYSTEM and USER environment
> >variable, but when I open up a Cygwin window it does not have this set.
> >It has all the other ones set, why did it unset this?
> 
> Never seen this so I can't help you there...
> 
> Larry Hall                              lhall AT rfk DOT com
> RFK Partners, Inc.                      http://www.rfk.com
> 118 Washington Street                   (508) 893-9779 - RFK Office
> Holliston, MA 01746                     (508) 893-9889 - FAX

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


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