[NTLUG:Discuss] run a program without ./

Randall Gibson wabbit at tvec.net
Thu Jul 20 23:57:05 CDT 2000


On Thu, 20 Jul 2000 23:27:43 m m wrote:
> Hi all:
> I have some questions:
> 
> 1. when I try to run a program, some of then need start with "./" and some 
> of them are not? how do I set all progrms can run without "./"?

This is done by the $PATH environment variable. do a "~$ echo $PATH" and you will everywhere a program will run without the path being specified. Generally having your home dir in path is a no-no (AFAIK). To change "~$ export PATH=/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games" adding the needed paths of course :)

> 
> 2. how do I add a script to init? in ther worlds, I want let ths script 
> start each time I boot my system. or tell me which HOWTO should I read.

on my system, this is done by putting a shell script in the /etc/init.d/ directory. May be different for others. A good list of how-to's is at : http://www.linuxdoc.org/HOWTO/HOWTO-INDEX/howtos.html . 

need more ? ICQ 2502581

Randall Gibson





More information about the Discuss mailing list