#! /bin/bash set -e launch_common() { xbindkeys xscreensaver & mpd --kill || true mpd for script in ~/.xlaunch.d/*; do "$script" done } launch_specialized() { # XXX dunst lazily started by dbus local -r scripts_dir=~/.xlaunch.d."$(hostname)" if test -f "$scripts_dir" then for script in "$scripts_dir"/*; do "$script" done fi } launch_common launch_specialized exec dwm