dotfiles

.config/bspwm/bspwmrc [raw] [blame]
 1#!/usr/bin/env sh
 2
 3if [ -x ~/.fehbg ]; then ~/.fehbg; fi
 4
 5pgrep -x dunst > /dev/null || dunst &
 6systemctl --user start polybar.service
 7systemctl --user start bspwm.service
 8
 9bspc monitor -d 1 2 3 4 5 6 7 8 9 0
10
11primary_resolution="$(xrandr | grep 'primary' | awk '{ print $4 }')"
12if [[ "$primary_resolution" = "1366x"* ]]; then
13  bspc config split_ratio 0.60
14  bspc config border_width 2
15  bspc config window_gap 5
16else
17  bspc config split_ratio 0.50
18  bspc config border_width 4
19  bspc config window_gap 40
20fi
21bspc config top_padding 10
22
23bspc config borderless_monocle true
24bspc config gapless_monocle true
25
26bspc config normal_border_color "#130A20"
27bspc config focused_border_color "#D0996E"
28
29bspc rule -a "firefox:Toolkit" state=floating border=off sticky=on rectangle=600x400+3250+1200
30
31if [[ "$primary_resolution" = "1366x"* ]]; then
32  bspc rule -a 'com.mitchellh.ghostty:scratch' sticky=on state=floating hidden=on rectangle=1362x250+0+30
33else
34  bspc rule -a 'com.mitchellh.ghostty:scratch' sticky=on state=floating hidden=on
35fi