Added /usr/local/pgsql/man and /usr/share man to MANPATH.
Build MANPATH dynamically like other PATHs.
This commit is contained in:
parent
c25f76b810
commit
af52301313
21
.zshenv
21
.zshenv
|
@ -77,7 +77,26 @@ if [ -r /etc/MANPATH ]
|
||||||
then
|
then
|
||||||
MANPATH=`cat /etc/MANPATH`:$MANPATH
|
MANPATH=`cat /etc/MANPATH`:$MANPATH
|
||||||
else
|
else
|
||||||
MANPATH=/usr/local/qmail/man:/usr/man:/usr/local/man:/usr/X11R6/man
|
ALL_PATH=/usr/local/qmail/man:/usr/man:/usr/local/man:/usr/X11R6/man:/usr/share/man:/usr/local/pgsql/man
|
||||||
|
NEW_PATH=""
|
||||||
|
|
||||||
|
for i in ${(s/:/)ALL_PATH}
|
||||||
|
do
|
||||||
|
if test -d "$i"
|
||||||
|
then
|
||||||
|
case "$NEW_PATH" in
|
||||||
|
$i:*|*:$i|*:$i:*) ;;
|
||||||
|
*)
|
||||||
|
if test -z "$NEW_PATH"
|
||||||
|
then
|
||||||
|
NEW_PATH=$i
|
||||||
|
else
|
||||||
|
NEW_PATH=$NEW_PATH:$i
|
||||||
|
fi
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
MANPATH=$NEW_PATH
|
||||||
fi
|
fi
|
||||||
export MANPATH
|
export MANPATH
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue