Search This Blog

Sunday 31 January 2010

Adding Directory to a Path

Pre and Post Pathing

Linux determines the executable search path with the $PATH environment variable. To add directory /data/myscripts to the beginning of the $PATH environment variable, use the following:

PATH=/data/myscripts:$PATH

To add that directory to the end of the path, use the following command:

PATH=$PATH:/data/myscripts