[ale] first time shell script

Geoffrey esoteric at 3times25.net
Tue May 6 16:16:39 EDT 2003


dino wrote:
> I have been doing some reading about shell scripts and have some 
> questions.  I am using the BASH shell on Mac's OSX.
> 
> Most sample scripts say to change the file to an executable via "chmod 
> u+x scriptname"
> After doing this i should be able to simply type in "scriptname" and it 
> should run.
> 
> I cant seem to get this to work, I must enter it like this
> "bash scriptname"

It could be that your perms were not set properly, or that your current 
directory is not in your path.  Do the following to see the perms on the 
script:

ls -l scriptname

The first four characters should be '-rwx'  or at least '-r-x'

As for the path issue, do this:

PATH=$PATH:.; export PATH

and then attempt your shell script as:

scriptname


> 
> is this normal or am I not doing something correct?
> 
> _______________________________________________
> Ale mailing list
> Ale at ale.org
> http://www.ale.org/mailman/listinfo/ale
> 
> 

-- 
Until later: Geoffrey		esoteric at 3times25.net

The latest, most widespread virus?  Microsoft end user agreement.
Think about it...

_______________________________________________
Ale mailing list
Ale at ale.org
http://www.ale.org/mailman/listinfo/ale





More information about the Ale mailing list