summaryrefslogtreecommitdiff
path: root/.config/wmii-hg/rbar.sh
diff options
context:
space:
mode:
Diffstat (limited to '.config/wmii-hg/rbar.sh')
-rw-r--r--.config/wmii-hg/rbar.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/.config/wmii-hg/rbar.sh b/.config/wmii-hg/rbar.sh
index 0c9efa6..287f427 100644
--- a/.config/wmii-hg/rbar.sh
+++ b/.config/wmii-hg/rbar.sh
@@ -1,4 +1,9 @@
#!/hint/bash
+if [[ -z "$XDG_RUNTIME_DIR" ]]; then
+ printf "XDG_RUNTIME_DIR isn't set\n" >&2
+ exit 6
+fi
+
setup_trap() {
trap "rm -f -- \"\${XDG_RUNTIME_DIR}\"/n/wmii*/rbar/${1}" EXIT
}