Skip to content

Instantly share code, notes, and snippets.

@qolarnix
Created January 7, 2023 14:21
Show Gist options
  • Save qolarnix/494956eccea992dee0ad41f3c4a072e9 to your computer and use it in GitHub Desktop.
Save qolarnix/494956eccea992dee0ad41f3c4a072e9 to your computer and use it in GitHub Desktop.
bspwm config
#! /bin/sh
# launch sxhkd keybind manager
pgrep -x sxhkd > /dev/null || sxhkd &
# launch script that runs polybar status bar
$HOME/.config/polybar/launch.sh &
# launch gnome polkit for programs that need auth
exec /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 &
# launch the compositor for shadows, transparency etc..
xcompmgr &
# screen layout (default.sh generated from arandr)
# its just a xrandr script. Could also use the following:
# xrandr --output Virtual1 --mode 2560x1440
$HOME/.screenlayout/default.sh &
# set xrandr dpi if you need to. you probably dont.
xrandr --dpi 60 &
# wallpaper setter
nitrogen --restore &
# dock (if you want to use plank but plank sucks)
# XDG_SESSION_TYPE=X11 plank &
# workspaces
# bspc monitor HDMI-0 -d 1 2
bspc monitor DP-4 -d 1 2 3 4 5 6 7
bspc monitor DP-3 -d 8 9
# decorations
# width of colored border around windows
bspc config border_width 1
# space inbetween windows
bspc config window_gap 10
# border colors based on the window state
bspc config normal_border_color "#787C99"
bspc config focused_border_color "#7AA2F7"
bspc config urgent_border_color "#2A2A2A"
# if you need to add padding below the screen for a dock or something similar
bspc config -m Virtual1 bottom_padding 0
# wm settings
# when you have 2 windows open if they should split in the center
# this should be set to 0.50
bspc config split_ratio 0.50
# no idea what this shit is but true
bspc config borderless_monocle true
bspc config gapless_monocle true
# Multihead behavior
# this doesnt really matter either but true
bspc config remove_disabled_monitors true
bspc config remove_unplugged_monitors true
# if you are using nvidia and alacritty you need this because nvidia very shit
# bspc config pointer_motion_interval 60
# rules
# floating terminal in the bottom right of screen, works with 1440p monitor
bspc rule -a '*:*:alacritty-floating' state=floating center=off follow=on border=on rectangle=800x600+1700+800
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment