This repository has been archived on 2024-03-28. You can view files and clone it, but cannot push or open issues or pull requests.
dotfiles/apps/de/sxhkd/rc

264 lines
8 KiB
Plaintext
Raw Normal View History

2017-02-07 16:16:45 -06:00
# node manager shortcuts
# focus the node for the given path jump
super + {p,b,comma,period}
bspc node -f @{parent,brother,first,second}
# set modes to tiled/floating for current node
super + {s,f}
bspc node -t {tiled,floating}
# set modes to pseudo_tiled/fullscreen for current node
super + shift + {s,f}
bspc node -t {pseudo_tiled,fullscreen -l above}
# focus the last node/desktop
super + {grave,Tab}
bspc {node,desktop} -f last
# focus the next floating node
super + ctrl + f
bspc node -f next.floating
# swap positions with the previous node
super + apostrophe
bspc node -s last
# swap the current node with the biggest node on the current desktop
super + m
bspc node -s biggest
# move/swap between nodes using vim-style arrows
super + {_,shift + }{h,j,k,l}
bspc node -{f,s} {west,south,north,east}
# swap previous/next desktops
2018-11-08 10:49:00 -06:00
2017-02-07 16:16:45 -06:00
super + bracket{left,right}
bspc desktop -f {prev,next}
# preselect the splitting area for the current node
2017-07-27 14:07:18 -05:00
super + ctrl + {h,j,k,l}
2017-02-07 16:16:45 -06:00
bspc node -p {west,south,north,east}
# clear the splitting area
super + ctrl + {_,shift + }space
bspc {node -p cancel,desktop -c}
# expand the current node
super + alt + {h,j,k,l}
bspc node {@west -r -10,@south -r +10,@north -r -10,@east -r +10}
# shrink the current node
super + alt + shift + {h,j,k,l}
bspc node {@east -r -10,@north -r +10,@south -r -10,@west -r +10}
# set node split ratio
2017-07-27 14:07:18 -05:00
super + ctrl + {1-9}
bspc node -o 0.{1-9}
2017-02-07 16:16:45 -06:00
# move a floating window very slowly
super + shift + {Left,Down,Up,Right}
2017-07-27 14:07:18 -05:00
bspc node --move {-1 0, 0 1, 0 -1, 1 0}
2017-02-07 16:16:45 -06:00
# move a floating window
super + {Left,Down,Up,Right}
2017-07-27 14:07:18 -05:00
bspc node --move {-20 0, 0 20, 0 -20, 20 0}
2017-02-07 16:16:45 -06:00
# focus/move node to the selected desktop
super + {_,shift + }{1-9,0}
2020-01-20 09:12:52 -06:00
bspc {desktop -f,node -d} {1-9,10}
2017-02-07 16:16:45 -06:00
2017-07-27 14:07:18 -05:00
# # focus clicked node
2017-02-07 16:16:45 -06:00
~button1
bspc node -f pointed
2018-11-08 10:49:00 -06:00
# set the current node's dimensions to 1920x1080 (for streaming)
2017-11-13 15:55:11 -06:00
super + shift + alt + ctrl + s
wres1080
2017-07-27 14:07:18 -05:00
# # mouse controls for node movement and resizing
# super + button{1-3}
# bspc pointer -g {move,resize_side,resize_corner}
2017-02-07 16:16:45 -06:00
2017-07-27 14:07:18 -05:00
# # simulate mouse2
# shift + super + button1
# bspc pointer -g resize_corner
2017-02-07 16:16:45 -06:00
2017-07-27 14:07:18 -05:00
# # ???
# super + !button{1-3}
# bspc pointer -t %i %i
2017-02-07 16:16:45 -06:00
2017-07-27 14:07:18 -05:00
# # ???
# super + @button{1-3}
# bspc pointer -u
2017-02-07 16:16:45 -06:00
# change node gap and desktop padding
super + plus
bspc config -d focused window_gap $((`bspc config -d focused window_gap` + 5 ))
super + equal
bspc config -m $(bspc query -M | head -n 1) top_padding $TOP_BAR_PADDING; bspc config -m $(bspc query -M | head -n 1) bottom_padding $BOTTOM_BAR_PADDING; bspc config -d focused window_gap $WINDOW_GAP
super + minus
bspc config -d focused window_gap $((`bspc config -d focused window_gap` - 5 ))
super + alt + r
bspc config -m $(bspc query -M | head -n 1) bottom_padding $BOTTOM_BAR_PADDING; bspc config -m $(bspc query -M | head -n 1) top_padding $TOP_BAR_PADDING; bspc config -d focused window_gap $WINDOW_GAP
super + alt + equal
bspc config -d focused bottom_padding 0; bspc config -d focused top_padding 0; bspc config -d focused left_padding 0; bspc config -d focused right_padding 0
super + alt + plus
bspc config -d focused bottom_padding $(expr $(bspc config -d focused bottom_padding) + 5); bspc config -d focused top_padding $(expr $(bspc config -d focused top_padding) + 5); bspc config -d focused left_padding $(expr $(bspc config -d focused left_padding) + 5); bspc config -d focused right_padding $(expr $(bspc config -d focused right_padding) + 5)
super + ctrl + alt + k
bspc config -d focused bottom_padding $(expr $(bspc config -d focused bottom_padding) - 5); bspc config -d focused top_padding $(expr $(bspc config -d focused top_padding) - 5)
super + ctrl + alt + j
bspc config -d focused bottom_padding $(expr $(bspc config -d focused bottom_padding) + 5); bspc config -d focused top_padding $(expr $(bspc config -d focused top_padding) + 5)
super + ctrl + alt + h
bspc config -d focused left_padding $(expr $(bspc config -d focused left_padding) - 5); bspc config -d focused right_padding $(expr $(bspc config -d focused right_padding) - 5)
super + ctrl + alt + l
bspc config -d focused left_padding $(expr $(bspc config -d focused left_padding) + 5); bspc config -d focused right_padding $(expr $(bspc config -d focused right_padding) + 5)
super + alt + plus
bspc config -d focused bottom_padding $(expr $(bspc config -d focused bottom_padding) + 5); bspc config -d focused top_padding $(expr $(bspc config -d focused top_padding) + 5); bspc config -d focused left_padding $(expr $(bspc config -d focused left_padding) + 5); bspc config -d focused right_padding $(expr $(bspc config -d focused right_padding) + 5)
2017-07-25 19:13:52 -05:00
super + ctrl + alt + shift + space
bspc config -d focused bottom_padding 0; bspc config -d focused top_padding 0; bspc config -d focused left_padding 0; bspc config -d focused right_padding 0
2017-02-07 16:16:45 -06:00
super + ctrl + alt + space
bspc config -d focused bottom_padding 200; bspc config -d focused top_padding 200; bspc config -d focused left_padding 400; bspc config -d focused right_padding 400
super + alt + minus
bspc config -d focused bottom_padding $(expr $(bspc config -d focused bottom_padding) - 5)
# rotate the current node
super + r
bspc node -R 90
2019-09-26 12:04:23 -05:00
# balance the current node's leaves
2017-02-07 16:16:45 -06:00
super + shift + b
bspc node -B
2019-09-26 12:04:23 -05:00
# balance the current node's sibling leaves
super + ctrl + b
bspc node -f parent && bspc node -B
2018-11-08 10:49:00 -06:00
# wm-independant shortcuts
# spawn a transparent node
super + alt + t
2020-01-20 10:49:06 -06:00
"$TERMINAL" && compton-trans -c -o 0
2018-11-08 10:49:00 -06:00
2017-02-07 16:16:45 -06:00
# make current node transparent
super + t
compton-trans -c -o 0
# make current node fully opaque
super + shift + t
compton-trans -c -o 100
2019-05-08 13:31:23 -05:00
# swap sxhkd config with an alternate file and reload the new one
2017-02-07 16:16:45 -06:00
# super + shift + alt + ctrl + r
# if [ -e ~/.config/sxhkd/altsxhkdrc ]; then mv ~/.config/sxhkd/sxhkdrc ~/.config/sxhkd/origsxhkdrc && mv ~/.config/sxhkd/altsxhkdrc ~/.config/sxhkd/sxhkdrc && pkill -USR1 -x sxhkd; fi
# spawn a terminal
super + Return
2020-01-20 10:49:06 -06:00
"$TERMINAL"
2019-05-08 13:31:23 -05:00
# spawn a rock-solid and reliable terminal for when I break things
super + alt + Return
2019-05-08 13:31:23 -05:00
urxvt
2017-02-07 16:16:45 -06:00
# spawn a floating terminal
2017-02-07 16:16:45 -06:00
super + shift + Return
2020-01-20 10:49:06 -06:00
bspc rule -a '*' -o state=floating && "$TERMINAL"
2017-02-07 16:16:45 -06:00
# spawn the app launcher
super + space
app-launcher -modi run -show run
2017-02-07 16:16:45 -06:00
# lock the desktop
super + ctrl + shift + l
dm-tool switch-to-greeter
2017-02-07 16:16:45 -06:00
# $SHELL -c '$DOTFILES_PATH/env/x/screensaver/lock.sh'
# spawn gui file explorer
super + e
thunar
# volumes controls and media navigation for media keys
{_,shift + }XF86AudioLowerVolume
amixer -D pulse sset Master 5%-
2019-11-21 15:41:35 -06:00
# pulseaudio-ctl lower
2017-02-07 16:16:45 -06:00
# ADJ={10,1} && amixer -c 1 sset Speaker $ADJ%- && amixer -c 1 sset Headphone $ADJ%- && amixer -c 1 sset Master $ADJ%- && update_bar_MasterVolume
{_,shift + }XF86AudioRaiseVolume
amixer -D pulse sset Master 5%+
2019-11-21 15:41:35 -06:00
# pulseaudio-ctl raise
2017-02-07 16:16:45 -06:00
# ADJ={10,1} && amixer -c 1 sset Speaker $ADJ%+ && amixer -c 1 sset Headphone $ADJ%+ && amixer -c 1 sset Master $ADJ%+ && update_bar_MasterVolume
XF86AudioMute
amixer -D pulse sset Master toggle
# pulseaudio-ctl mute
# amixer -c 1 sset Master toggle && update_bar_MasterVolume
XF86AudioPlay
mpc toggle
XF86AudioNext
mpc next
XF86AudioPrev
mpc prev
# monitor brightness controls for monitor birghtness keys
{_,shift + }XF86MonBrightnessUp
xbacklight + 10
2017-02-07 16:16:45 -06:00
{_,shift + }XF86MonBrightnessDown
xbacklight - 10
2017-02-07 16:16:45 -06:00
# open rofi as a window switcher
super + w
2020-01-20 14:01:06 -06:00
"app-launcher" -modi window,run -show window
2020-01-23 12:38:19 -06:00
super + shift + v
2020-01-24 12:45:49 -06:00
sh -c 'kill -USR1 $(cat "/var/run/user/$UID/polybar-mic-script.sh.pid")'
2020-01-23 12:38:19 -06:00
2020-01-28 09:59:03 -06:00
super + shift + v
sh -c 'kill -USR1 $(cat "/var/run/user/$UID/polybar-mic-script.sh.pid")'
2020-01-28 09:45:04 -06:00
super + shift + e
2020-03-06 15:43:01 -06:00
rofimoji --insert-with-clipboard --rofi-args='--sort -sorting-method fzf'
2020-01-28 09:45:04 -06:00
super + shift + p
rofi-pass
2017-02-07 16:16:45 -06:00
# close the current application
super + c
bspc node -c
# kill the current application
super + shift + c
bspc node -k
# kill the wm, if alt is held, it will reload instead of truly quitting...
# I think?
super + ctrl + {alt +,_} Escape
2020-01-23 12:38:19 -06:00
sh -c '{bspc wm -d > "$BSPWM_STATE_FILE" && bspc quit, bspc quit 1}'
2017-02-07 16:16:45 -06:00
# make sxhkd reload its configuration files:
super + Escape
pkill -USR1 -x sxhkd
2019-07-24 11:23:18 -05:00
2019-08-06 12:33:23 -05:00
super + ctrl + c
2020-01-20 10:49:06 -06:00
bspc rule -a '*' -o state=floating && urxvt --geometry 64x9 -e sh -c "cal -n 3 && bash"