LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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!

Notices


Reply
  Search this Thread
Old 07-16-2004, 07:06 AM   #1
who_cares
LQ Newbie
 
Registered: Jul 2004
Posts: 11

Rep: Reputation: 0
Wink How do I change the $PATH to what I want permantly


I got the adobe plugin for mozilla 1.4.1 I have fedora core release 1 and it says I must have acroread in my path. the path is /usr/local/Acrobat-5/bin, I used the PATH="$PATH /usr/local/Acrobat-5/bin" at the command line echoed the $PATH and it was there. I rebooted and done a $PATH echo and it werent there. I used the symlink method instead and I can read PDF documents happily, but I would still like to know how I can change the $PATH permantly in case I may have to in the future
 
Old 07-16-2004, 07:07 AM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 269Reputation: 269Reputation: 269
Add it to your .bashrc or .bash_profile or /etc/profile for users globally.
 
Old 07-18-2004, 08:45 AM   #3
who_cares
LQ Newbie
 
Registered: Jul 2004
Posts: 11

Original Poster
Rep: Reputation: 0
cheers tricky seemed to do the trick
 
Old 07-20-2004, 07:47 AM   #4
mfazi1612
LQ Newbie
 
Registered: Jul 2004
Posts: 7

Rep: Reputation: 0
Hi, just following up from this post. When I opened my bashrc to add the line, it said:

# PLEASE DO NOT CHANGE /etc/bash.bashrc There are chances that your changes
# will be lost during system upgrades. Instead use /etc/bash.bashrc.local
# for your local settings, favourite global aliases, VISUAL and EDITOR

I couldn't find the .local file. Is this something I have to create? If so, do I just copy the original bashrc, and how do I get the system to look for this .local file instead of the original?
 
Old 07-20-2004, 09:05 AM   #5
who_cares
LQ Newbie
 
Registered: Jul 2004
Posts: 11

Original Poster
Rep: Reputation: 0
Talking just use etc/profiles files

Go into the etc folder select the profiles file choose to open with your favourite text editor.

You will see a a series of pathmunge statements this is a variable to set up your paths. they all start with a ;

Just after these without the comma (choose) a blank line put:

Pathmunge /your/path

This should work it did for me.

You will have to reboot to see the results in an echo $PATH at the command line.
 
Old 07-20-2004, 09:31 AM   #6
mfazi1612
LQ Newbie
 
Registered: Jul 2004
Posts: 7

Rep: Reputation: 0
Hi,

But that will edit the profile. As the script says in my post before, upgrades could affect the profile so don't change that, instead change the profile.local.

I assume this means, upon upgrades, your profile could change so instead put your paths in a local version of your profile. I couldn't find this local version and was wondering how do I find it/set it up?

Thanks.
 
Old 07-20-2004, 09:50 AM   #7
mikshaw
LQ Addict
 
Registered: Dec 2003
Location: Maine, USA
Distribution: Slackware/SuSE/DSL
Posts: 1,320

Rep: Reputation: 45
You can create it...it's just a text file.
Another option is copy /etc/bashrc(or bash_profile) to $HOME/.bashrc(or .bash_profile) and edit it to your pleasure. This leaves the system-wide settings untouched, and any upgrades won't affect your personal settings. I prefer doing this because 1) I can't screw up too severely by messing with system-wide settings, and 2) every user of the system can have his own choice of setting which can be easily backed up and transferred to other systems.
 
Old 07-20-2004, 09:56 AM   #8
mfazi1612
LQ Newbie
 
Registered: Jul 2004
Posts: 7

Rep: Reputation: 0
Thanks
 
Old 07-20-2004, 10:10 AM   #9
320mb
Senior Member
 
Registered: Nov 2002
Location: pikes peak
Distribution: Slackware, LFS
Posts: 2,577

Rep: Reputation: 48
Quote:
Originally posted by mfazi1612
Hi,

But that will edit the profile. As the script says in my post before, upgrades could affect the profile so don't change that, instead change the profile.local.

I assume this means, upon upgrades, your profile could change so instead put your paths in a local version of your profile. I couldn't find this local version and was wondering how do I find it/set it up?

Thanks.
just make a back up of the file/files!!!
if something odd happens during an upgrade........just restore it..............easy
 
  


Reply



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
Free Opera (permantly) stabile007 General 10 09-21-2005 12:37 AM
keep change in PATH alchem Linux - Newbie 11 08-28-2005 04:08 PM
permantly removing a program from apt-get diensthunds Debian 7 03-06-2005 02:41 PM
How do I change PATH? trotsky Linux - Software 4 12-28-2004 01:08 PM
How do i change the $PATH explorer Fedora 6 10-24-2004 03:21 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:31 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration