bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bash Path Duplications: An idea from zsh


From: Steven W. Orr
Subject: Re: Bash Path Duplications: An idea from zsh
Date: Mon, 7 Jan 2002 23:38:11 -0500 (EST)

On Thu, 3 Jan 2002, Chet Ramey wrote:

=>> There has been considerable recent discussion on the redhat-list
=>> regarding path setting in Red Hat Linux and therefore in bash, their
=>> default shell.  The discussion centers around the common event of
=>> multiple instances of the same directory(s) within path entries, flowing
=>> in part from multiple invocations of bash startup files.  A common work
=>> around is conditional appendages to PATH, based on echo | grep tests.  Some
=>> discussants find this inelegant and seek a better way to do this.
=>
=>This is so trivial to do with shell functions that it's not worth
=>putting into the shell proper.  Look at examples/functions/pathfuncs
=>in the bash distribution for guidance.
=>
=>The `case' statement and the [[...]] conditional command are your friends.
=>There should be no need to resort to `echo | grep' tests.
Chet, I almost agree with you :-)

I have a program called envv written in perl which is used to edit the 
values of environment variables which are colon seperated lists. Very 
handy.

Write me if you're interested. :-)

-- 
-Time flies like the wind. Fruit flies like a banana. Stranger things have -
-happened but none stranger than this. Does your driver's license say Organ
-Donor?Black holes are where God divided by zero. Listen to me! We are all-
-individuals! What if this weren't a hypothetical question? steveo@syslang.net





reply via email to

[Prev in Thread] Current Thread [Next in Thread]