M bin/start-barrier => bin/start-barrier +1 -1
@@ 1,5 1,5 @@
#!/usr/bin/env sh
# Stop the process with:
-# killall barrierc
+# pkill -x barrierc
barrierc --no-tray "$@" &
setxkbmap -device "$(xinput list --id-only "Virtual core XTEST keyboard")" "gb"
A bin/start-lemonbar => bin/start-lemonbar +15 -0
@@ 0,0 1,15 @@
+#!/usr/bin/env sh
+pkill -f lemons
+
+readonly lemons_log="/tmp/lemons_""$XDG_SESSION_ID"".txt"
+
+LEMONBAR_PIPE="/tmp/lemonbar_pipe_""$XDG_SESSION_ID"
+export LEMONBAR_PIPE
+
+# setsid necessary so pkill-ing lemonbar doesn't bring down the parent
+# process with it.
+setsid /usr/bin/lemons \
+ -g "x26" \
+ -f "Roboto Mono:style=Medium:antialias=true:autohint=true:pixelsize=13" \
+ -f "Roboto Mono:style=Bold:antialias=true:autohint=true:pixelsize=13" \
+ > "$lemons_log" 2>&1 &
M bin/start-vncserver => bin/start-vncserver +4 -1
@@ 1,4 1,7 @@
#!/usr/bin/env sh
-exec /usr/bin/systemd-inhibit \
+# autorandr postswitch hook is responsible for restarting lemonbar
+trap "autorandr --load default" EXIT INT TERM QUIT
+autorandr --load vnc
+systemd-inhibit \
--what="sleep:handle-lid-switch" --why="Keep VNC alive" \
x0vncserver -rfbauth "$HOME""/.vnc/passwd"
M bspwm/bspwmrc => bspwm/bspwmrc +7 -13
@@ 1,20 1,10 @@
#!/usr/bin/env sh
-
readonly gray="#c8c8c8"
readonly white="#dadada"
sxhkd &
-LEMONBAR_PIPE="/tmp/lemonbar_pipe_""$XDG_SESSION_ID"
-export LEMONBAR_PIPE
-
-readonly lemons_log_file="/tmp/lemons_""$XDG_SESSION_ID"".txt"
-
-lemons \
- -g "x26" \
- -f "Roboto Mono:style=Medium:antialias=true:autohint=true:pixelsize=13" \
- -f "Roboto Mono:style=Bold:antialias=true:autohint=true:pixelsize=13" \
- > "$lemons_log_file" 2>&1 &
+start-lemonbar
# TODO(rycwo): xrandr --listmonitors might be more reliable
IFS='\n' read -ra monitors <<< "$(bspc query -M)"
@@ 28,8 18,12 @@ bspc config focused_border_color "$gray"
bspc config split_ratio 0.5
bspc config border_width 1
-bspc config window_gap 24
+bspc config window_gap 2
-# Monocle layout settings.
+# Monocle layout settings
bspc config borderless_monocle true
bspc config gapless_monocle true
+bspc config single_monocle true
+
+# Temporary rules
+bspc rule -a Borann state=floating