summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHugues Hiegel <hugues@hiegel.fr>2008-03-04 16:07:16 +0100
committerHugues Hiegel <hugues@hiegel.fr>2008-03-07 14:15:22 +0100
commit58d36b2d4d4e6b5234f08e3a378c4a624819b728 (patch)
tree8f1ffa12979573e35a099c7fb548822e24bce627
parentc2678cd0b3b927694c57c46a35acf232c76e8774 (diff)
Ajout des fichiers per-host/per-user dans le parsing.
-rw-r--r--.zshrc10
1 files changed, 7 insertions, 3 deletions
diff --git a/.zshrc b/.zshrc
index bbea785..323188e 100644
--- a/.zshrc
+++ b/.zshrc
@@ -34,7 +34,7 @@ HOST=${HOST:-$(hostname -s)}
DOMAIN=${DOMAIN:-${$(hostname -d 2>&-):-$(hostname -y 2>&-)}}
[ $DOMAIN = "" -o $DOMAIN = "localdomain" -o $DOMAIN = "(none)" ] && DOMAIN=$(grep "^search " /etc/resolv.conf | cut -d' ' -f2)
-DEBUG=no
+DEBUG=${DEBUG:-no}
export USER HOST DOMAIN UID
@@ -52,14 +52,18 @@ if [ -d $ZDOTDIR ]; then
"user:$SUDO_USER"\
"net:$DOMAIN/host:$HOST"\
"net:$DOMAIN/user:$USER"\
+ "net:$DOMAIN/user:$SUDO_USER"\
"net:$DOMAIN/host:$HOST/user:$USER"\
- "net:$DOMAIN/host:$HOST/user:$SUDO_USER"
+ "net:$DOMAIN/host:$HOST/user:$SUDO_USER"\
+ "host:$HOST/user:$USER"\
+ "host:$HOST/user:$SUDO_USER"
do
specific_script=${script:h}/$i/${${script:t}/??_/}
if test -f $specific_script
then
- [ "$DEBUG" = "yes" ] && echo "$i/${${specific_script:t:r}/??_/}... ";
+ [ "$DEBUG" = "yes" ] && echo -n "$i/${${specific_script:t:r}/??_/}... ";
source $specific_script
+ [ "$DEBUG" = "yes" ] && echo
fi
done
done