Visit Jeremy's Blog.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 06-01-2004, 02:48 PM   #1
Registered: May 2004
Location: Austria
Posts: 30

Rep: Reputation: 15
$path variable ?

Hi All

Question , if i create a /bin directory in /home/mine and put some shell scripts in it will they be picked up by the $PATH variables or are the $PATH variables only interested in searching the /dir .
The reason is that i'm creating small scripts and i would like them to run directory wide in my home dir , and try to keep them separate from root/bin.

Cheers Moby
Old 06-01-2004, 02:52 PM   #2
Registered: May 2003
Location: USA
Distribution: Fedora 21, RHEL 5,6&7, Windoze 7
Posts: 235

Rep: Reputation: 31
You'll need to add it to your .bash_profile file
in your home directory. Then log out and back in.
The n run the env command to see if it is now in your PATH.

good luck
Old 06-01-2004, 02:54 PM   #3
Registered: Aug 2003
Location: N.C.
Distribution: rh9, fc1, slack 9.1, 10
Posts: 229

Rep: Reputation: 30
you can find out what directories are in your PATH by typing:
echo $PATH
to make permanent change you can edit your .bash_profile file which should be in your home directory, (type ls -al to check) and add the path that you need. but be careful with this, as changing your path can be a security risk. another possible solution is to put the script in a directory that is already in your PATH.

hope this helps.
Old 06-01-2004, 03:18 PM   #4
Registered: May 2004
Location: Austria
Posts: 30

Original Poster
Rep: Reputation: 15
Well since i canny find .bash_profile , i can find .bashrc & .bash_history .

based on the above i think placing the script in an already existing PATH
is the best bet .

Thank's for the Quick responce

Cheers Moby


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Changing the PATH variable pppaaarrrkkk Linux - Newbie 1 12-01-2005 09:00 PM
PATH variable jk21 Linux - Newbie 1 09-28-2004 02:48 PM
the path variable mjkramer Linux - Newbie 4 10-18-2003 07:18 AM
PATH variable file pongsu Linux - General 2 09-25-2003 04:13 AM
setting path variable shahrahulb Linux - General 2 07-30-2003 08:25 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:23 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration