[wplug] PATH housekeeping

Weber, Larry A laweber at switch.com
Thu Oct 4 10:05:11 EDT 2001


Thanks for the suggestions.  Although RH7.1 uses a bash shell I cannot find
a .bash_profile or .bashrc file.

> -----Original Message-----
> From:	harrold at sage.che.pitt.edu [SMTP:harrold at sage.che.pitt.edu]
> Sent:	Thursday, October 04, 2001 9:32 AM
> To:	wplug at wplug.org
> Subject:	Re: [wplug] PATH housekeeping
> 
> Sometime in October Weber, Larry A assaulted keyboard and produced...
> 
> |I have been trying to clean up the default $PATH.  Currently there are
> |duplicate directory searches that I would like to clean out.  I have
> |searched /etc but cannot find a file(s) that set $PATH to the value
> echoed.
> |Even if there are multiple files building it, the segments don't match
> up.
> |I am using RH7.1 and find $PATH being set (absolutely or conditionally)
> in
> |several places, particularly in /etc rc.sysinit, profile, and csh.login,
> and
> |anacrontab.  Again, none of these, or any combination, are building the
> |default $PATH.
> |
> |I have installed updated versions of some of the tools that were
> installed
> |by the distro (gcc, and others).  I don't want to blow away the original
> yet
> |so I installed them into /usr/local/.  I would like the new versions to
> be
> |found first.  I have considered three ways, alias, ln, and changing the
> path
> |search order.  Whatever I do, I don't want to have to redo every time I
> open
> |a terminal or reboot.  And it would be nice if it where the same for all
> |users.  Any suggestions as to the best way?
> |
> 
> you could just reassign the path to what you want. in bash i dont recall
> which is loaded last .bash_profile or .bashrc; in which ever is last you
> could export the path you want (not inculding the current $PATH). this
> would overwrite any predefined paths. after figuring out which of the
> above
> files is loaded last (or if you're using something like tcsh-what ever rc
> type file it uses), you could write a script to echo the path to all the
> users
> conf files on your system. this would take care of current users. then
> make
> the same changes in /etc/skel to cover future users.
> 
> this isnt the cleanest way of doing things, but if alot of stuff is being
> loaded this is one way to overwrite everything.
> 
> -- 
> john
> -dirt it's what we die for.
> 
> _______________________________________________
> wplug mailing list
> wplug at wplug.org
> http://www.wplug.org/mailman/listinfo/wplug



More information about the wplug mailing list