TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [TCLUG:751] Problem running scripts - Need Advice
>>> "Joseph A. Heil" <heilja@dbsource.com> 07/29 8:20 AM >>>
What you really want is to include your current directory, that
way instead of ". foo" , just run "foo". The path then should then
be this "$PATH = /bin:/usr/bin:/." The "." should be the last entry
in the path statement, otherwise you might end up running a custom
version of a program when you might have want the standard version
which
would be found the the standard bin directories.
>>>>>>
I prefer to not have the current directory in my path, so I have to
use the either
the full pathname:
/home/me/coolscript
or I have to run the script like this:
cd /home/me
./coolscript
This allows me the comfort of knowing I will not execute anything I
didn't mean
to by mistake, but if I am running this script all the time, for
convenience I'll put
it in my personal "bin" directory:
/home/me/bin
and make sure that that directory is in my $PATH variable. After I do
that I can
just type:
coolscript
at the prompt and the script will execute. But do what you feel
comfortable with,
and have a happy day,
Troy