summaryrefslogtreecommitdiff
path: root/bsc
diff options
context:
space:
mode:
Diffstat (limited to 'bsc')
-rwxr-xr-xbsc13
1 files changed, 13 insertions, 0 deletions
diff --git a/bsc b/bsc
index 8302d3b..5fec72b 100755
--- a/bsc
+++ b/bsc
@@ -21,6 +21,19 @@ while getopts "hwxd:u:" o; do case "${o}" in
esac done
#}}}
+#{{{ Check display server if -w or -x not provided
+if [ -z "$DMENU" ]; then
+ if [ -n "$WAYLAND_DISPLAY" ]; then
+ DMENU="bemenu"
+ elif [ -n "$DISPLAY" ]; then
+ DMENU="dmene"
+ else
+ print "Can't tell if Wayland or X; what gives?\n"
+ exit 1
+ fi
+fi
+#}}}
+
#{{{ Choose Profiles
PROFILES=`grep 'Path=' ~/.moonchild\ productions/basilisk/profiles.ini | cut -d'.' -f2`
CHOSEN=`echo "$PROFILES" | $DMENU -p "basilisk" -l 15 $DMENU_ARGS`