Avoid training :'s in paths
When the path was empty, path_push_unique would cause a training colon to be added. This was a known issue that didn't cause any harm, but while we're here, we'll clean this up.
This commit is contained in:
parent
aef982dd09
commit
0a56e643b1
|
@ -607,7 +607,11 @@ path_remove () {
|
||||||
path_push_unique () {
|
path_push_unique () {
|
||||||
x="$(eval echo \$$1)"
|
x="$(eval echo \$$1)"
|
||||||
x="$(path_remove "$x" "$2")"
|
x="$(path_remove "$x" "$2")"
|
||||||
eval export $1="$2:$x"
|
if test -z "$x"; then
|
||||||
|
eval export $1="$2"
|
||||||
|
else
|
||||||
|
eval export $1="$2:$x"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# tweak platform specific flags
|
# tweak platform specific flags
|
||||||
|
|
Loading…
Reference in New Issue