aboutsummaryrefslogtreecommitdiff
path: root/X
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2016-12-15 14:26:15 +1300
committerTom Ryder <tom@sanctum.geek.nz>2016-12-15 14:28:19 +1300
commit0bff2338642b1dab20c9a720e632691a46153a6a (patch)
treeeaa7efffe6c46d548c28bc1a833a7cf41979e16c /X
parentd235ffc6b1192662b86005cb6ce45866ffb12ac2 (diff)
downloaddotfiles-0bff2338642b1dab20c9a720e632691a46153a6a.tar.gz
dotfiles-0bff2338642b1dab20c9a720e632691a46153a6a.zip
Add command guards around .xinitrc.d subscripts
Diffstat (limited to 'X')
-rw-r--r--X/xinitrc.d/browser.sh1
-rw-r--r--X/xinitrc.d/dunst.sh1
-rw-r--r--X/xinitrc.d/mpdlrc.sh1
-rw-r--r--X/xinitrc.d/redshift.sh1
-rw-r--r--X/xinitrc.d/ssh.sh7
-rw-r--r--X/xinitrc.d/urxvt.sh1
-rw-r--r--X/xinitrc.d/xbindkeys.sh1
-rw-r--r--X/xinitrc.d/xkb.sh1
8 files changed, 10 insertions, 4 deletions
diff --git a/X/xinitrc.d/browser.sh b/X/xinitrc.d/browser.sh
index 84e8a7f2..cdb9b8c0 100644
--- a/X/xinitrc.d/browser.sh
+++ b/X/xinitrc.d/browser.sh
@@ -1,3 +1,4 @@
# Browser within X is Firefox
+command -v firefox >/dev/null 2>&1 || return
BROWSER=firefox
export BROWSER
diff --git a/X/xinitrc.d/dunst.sh b/X/xinitrc.d/dunst.sh
index 6aad0c86..bddaa1fe 100644
--- a/X/xinitrc.d/dunst.sh
+++ b/X/xinitrc.d/dunst.sh
@@ -1,2 +1,3 @@
# Start dunst(1) to display libnotify messages
+command -v dunst >/dev/null 2>&1 || return
dunst &
diff --git a/X/xinitrc.d/mpdlrc.sh b/X/xinitrc.d/mpdlrc.sh
index 1858f790..98f2d92a 100644
--- a/X/xinitrc.d/mpdlrc.sh
+++ b/X/xinitrc.d/mpdlrc.sh
@@ -1,2 +1,3 @@
# Start mpdlrc-notify-send <https://sanctum.geek.nz/cgit/mpdlrc.git/about/>
+command -v mpdlrc-notify-send >/dev/null 2>&1 || return
mpdlrc-notify-send &
diff --git a/X/xinitrc.d/redshift.sh b/X/xinitrc.d/redshift.sh
index 929f564e..d5d58d8a 100644
--- a/X/xinitrc.d/redshift.sh
+++ b/X/xinitrc.d/redshift.sh
@@ -1,2 +1,3 @@
# Start redshift(1)
+command -v redshift >/dev/null 2>&1 || return
redshift &
diff --git a/X/xinitrc.d/ssh.sh b/X/xinitrc.d/ssh.sh
index 2febe2c6..005743fe 100644
--- a/X/xinitrc.d/ssh.sh
+++ b/X/xinitrc.d/ssh.sh
@@ -1,5 +1,4 @@
# Set SSH_ASKPASS if we can find one
-if command -v ssh-askpass >/dev/null 2>&1 ; then
- SSH_ASKPASS=$(command -v ssh-askpass)
- export SSH_ASKPASS
-fi
+command -v ssh-askpass >/dev/null 2>&1 || return
+SSH_ASKPASS=$(command -v ssh-askpass)
+export SSH_ASKPASS
diff --git a/X/xinitrc.d/urxvt.sh b/X/xinitrc.d/urxvt.sh
index c86a3c88..a5eb0940 100644
--- a/X/xinitrc.d/urxvt.sh
+++ b/X/xinitrc.d/urxvt.sh
@@ -1,2 +1,3 @@
# Start urxvtd(1)
+command -v urxvtd >/dev/null 2>&1 || return
urxvtd -o -q &
diff --git a/X/xinitrc.d/xbindkeys.sh b/X/xinitrc.d/xbindkeys.sh
index 4dd1e31d..a21bd995 100644
--- a/X/xinitrc.d/xbindkeys.sh
+++ b/X/xinitrc.d/xbindkeys.sh
@@ -1,2 +1,3 @@
# Start xbindkeys(1)
+command -v xbindkeys >/dev/null 2>&1 || return
xbindkeys -n &
diff --git a/X/xinitrc.d/xkb.sh b/X/xinitrc.d/xkb.sh
index 32b7cf9a..a5142398 100644
--- a/X/xinitrc.d/xkb.sh
+++ b/X/xinitrc.d/xkb.sh
@@ -1,4 +1,5 @@
# Map Caps Lock as a Ctrl key, use right alt as Compose, kill X server with
# Ctrl+Alt+Backspace
# <https://en.wikipedia.org/wiki/Compose_key#Common_compose_combinations>
+command -v setxkbmap >/dev/null 2>&1 || return
setxkbmap -option compose:ralt,ctrl:nocaps,terminate:ctrl_alt_bksp