LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices

Reply
 
Search this Thread
Old 09-08-2005, 07:28 AM   #1
moonz
LQ Newbie
 
Registered: Sep 2005
Posts: 11

Rep: Reputation: 0
PATH environment variable


Hi
I want to add and remove varaíables in my PATH envionment varibles!
Thank you, i hope ;-)
 
Old 09-08-2005, 07:41 AM   #2
IBall
Senior Member
 
Registered: Nov 2003
Location: Perth, Western Australia
Distribution: Ubuntu, Debian, Various using VMWare
Posts: 2,088

Rep: Reputation: 61
To add directories to your $PATH, add the following line to /etc/profile (For System Wide), or ~/.bash_profile or ~/.bashrc (For individual users):
Code:
export PATH=$PATH:/path/to/directory
To remove directories from your $PATH, you need to find where they are set, (In the above files, or some other places depending on your distro), and remove the entry from the export PATH line.

I hope this helps
--Ian
 
Old 09-08-2005, 03:43 PM   #3
sonos391
LQ Newbie
 
Registered: Sep 2005
Posts: 1

Rep: Reputation: 0
Hi,

I simply could not locate where these vars were located for PATH! So, here is how I removed the unwanted entries...

1. the original path...
[patrick@iknomed avr]$ echo $PATH
/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/patrick/bin:/home/patrick/gccXdev/avr/tools/bin:/home/patrick/gccXdev/avr/toolchain/bin
[patrick@iknomed avr]$
2. copied the above and removed the unwanted entries and reassigned the entire PATH...
PATH=/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/patrick/bin:/home/patrick/gccXdev/avr/toolchain/bin

3. verified that it worked!
[patrick@iknomed avr]$ echo $PATH
/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/patrick/bin:/home/patrick/gccXdev/avr/toolchain/bin
[patrick@iknomed avr]$


HTH
 
Old 09-08-2005, 04:10 PM   #4
moonz
LQ Newbie
 
Registered: Sep 2005
Posts: 11

Original Poster
Rep: Reputation: 0
Hi thank you very much! Il try this out
moonz
 
  


Reply


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 path environment variable iNET_boss Linux - Newbie 2 07-27-2005 04:35 PM
Modifying the PATH environment variable brunnopessoa Linux - Newbie 11 11-03-2004 10:23 PM
edit path environment variable to include current working directory alb1954 Linux - Newbie 8 07-11-2004 11:26 PM
which path do the environment variable files reside in ycli00 Linux - General 1 03-03-2004 01:57 AM
how do I edit the $PATH environment variable in RH7.3 needamiracle Linux - Software 3 07-02-2002 09:19 PM


All times are GMT -5. The time now is 04:09 AM.

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