summaryrefslogtreecommitdiff
path: root/.config/wmii-hg/wmiirc
diff options
context:
space:
mode:
Diffstat (limited to '.config/wmii-hg/wmiirc')
-rwxr-xr-x.config/wmii-hg/wmiirc10
1 files changed, 6 insertions, 4 deletions
diff --git a/.config/wmii-hg/wmiirc b/.config/wmii-hg/wmiirc
index a7dd80c..396bed2 100755
--- a/.config/wmii-hg/wmiirc
+++ b/.config/wmii-hg/wmiirc
@@ -2,8 +2,10 @@
unset WMII_NAMESPACE
unset WMII_DIR
-export _PATH="$PATH"
-export PATH="$WMII_CONFPATH:$PATH"
+if [[ -z $_PATH ]]; then
+ export _PATH="$PATH"
+ export PATH="$WMII_CONFPATH:$PATH"
+fi
. include.sh
@@ -13,6 +15,6 @@ Event WmiircStart
trap "Event Quit" EXIT
-wmiir read /event 2>/dev/null | while read event; do
+while read -r event; do
Event $event
-done
+done < <(wmiir read /event 2>/dev/null)