From 4725ea90f7b8a3874f627756c0a8f7f2954c2030 Mon Sep 17 00:00:00 2001 From: omri Date: Sat, 3 Aug 2024 17:50:11 +0300 Subject: [PATCH] bspwm: add --- .config/bspwm/bspwmrc | 43 +++++++++++++++++ .config/bspwm/panel | 4 ++ .config/sxhkd/sxhkdrc | 106 ++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 153 insertions(+) create mode 100755 .config/bspwm/bspwmrc create mode 100755 .config/bspwm/panel create mode 100755 .config/sxhkd/sxhkdrc diff --git a/.config/bspwm/bspwmrc b/.config/bspwm/bspwmrc new file mode 100755 index 0000000..007f8dc --- /dev/null +++ b/.config/bspwm/bspwmrc @@ -0,0 +1,43 @@ +#!/usr/bin/env sh + +# Load colors from wal +[ -f "${HOME}/.cache/wal/colors.sh" ] && . "${HOME}/.cache/wal/colors.sh" + +# Define mod keys +mod=Mod4 # Usually the Super key +alt=Mod1 # Usually the Alt key +ctrl=Control +shift=Shift + +# Set bspwm settings +bspc monitor -d I II III IV V VI VII VIII IX X +bspc config border_width 2 +bspc config window_gap 12 +bspc config split_ratio 0.5 +bspc config border_color_normal $color0 +bspc config border_color_focus $color8 +bspc config border_color_urgent $color1 + +# Set bspwm rules +bspc rule -a "Cadence" floating=on +bspc rule -a "Lxpolkit" floating=on +bspc rule -a "Dragon-drag-and-drop" floating=on +bspc rule -a "dialog" floating=on +bspc rule -a "notification" manage=off +bspc rule -a "dock" manage=off +bspc rule -a "desktop" manage=off + +# Startup applications +sxhkd & +~/.config/bspwm/panel & +dunst & +mpd & +flameshot & +lxpolkit & +picom --experimental-backends & +wal -R +~/.fehbg + +# Panel +${HOME}/.config/bspwm/panel.sh + diff --git a/.config/bspwm/panel b/.config/bspwm/panel new file mode 100755 index 0000000..9151edb --- /dev/null +++ b/.config/bspwm/panel @@ -0,0 +1,4 @@ +#!/usr/bin/env bash + +polybar-msg cmd quit +polybar main 2>&1 & disown diff --git a/.config/sxhkd/sxhkdrc b/.config/sxhkd/sxhkdrc new file mode 100755 index 0000000..4881025 --- /dev/null +++ b/.config/sxhkd/sxhkdrc @@ -0,0 +1,106 @@ +# Keybindings + +# Basic +super + w + bspc node -c + +super + ctrl + r + bspc wm -r + +# Focus +super + h + bspc node -f west + +super + j + bspc node -f south + +super + k + bspc node -f north + +super + l + bspc node -f east + +# Shift +super + shift + h + bspc node -s west + +super + shift + j + bspc node -s south + +super + shift + k + bspc node -s north + +super + shift + l + bspc node -s east + +# Split focused frame +super + y + bspc node -p west +super + u + bspc node -p south +super + i + bspc node -p north +super + o + bspc node -p east + +# Resize +super + ctrl + {h,j,k,l} + bspc node -z {left -20 0,bottom 0 20,top 0 -20,right 20 0} + +# Cycle layouts +super + Tab + bspc desktop -l next + +# Window attributes +super + ctrl + e + bspc node -t floating +super + ctrl + w + bspc node -t fullscreen +super + ctrl + q + bspc node -t tiled + +# Media keys +XF86AudioMute + pulsemixer --toggle-mute +XF86AudioLowerVolume + pulsemixer --change-volume -5 +XF86AudioRaiseVolume + pulsemixer --change-volume +5 +XF86MonBrightnessDown + light -U 5 +XF86MonBrightnessUp + light -A 5 + +# Mouse +super + button1 + bspc node -s west +super + button2 + bspc node -p +super + button3 + bspc node -s east + +# Application launchers +super + Return + kitty + +super + space + rofi -show run + +super + grave + flameshot gui + +super + 1 + nemo + +super + 2 + brave + +super + 3 + rofi -show calc + +super + 4 + kitty -e nmcpcpp + +super + 0 + i3lock +