1
0
Fork 0

.config/sway: update

main
urosm 2024-06-12 00:48:42 +02:00
parent ff5952909b
commit d7c2fcaace
1 changed files with 128 additions and 126 deletions

View File

@ -29,7 +29,7 @@ set $wso 8:o:cmd
set $wsp 9:p:rdp
# modes
set $session_mode "session: (r)eload (l)ock (q)uit (s)uspend re(b)oot (p)oweroff"
set $session_mode "session: (r)eload (l)ock (q)uit (s)uspend (h)ibernate re(b)oot (p)oweroff"
set $layout_mode "layout: split(h) split(v) (s)tacking (t)abbed"
# commands
@ -68,7 +68,7 @@ bar {
workspace_layout tabbed
# xwayland #####################################################################
xwayland disable
# xwayland disable
# bindsym ######################################################################
# floating
@ -95,24 +95,24 @@ bindsym {
}
# move
bindsym {
bindsym --to-code {
$mod+shift+$up move up
$mod+shift+$down move down
$mod+shift+$left move left
$mod+shift+$right move right
--to-code $mod+shift+tab move workspace back_and_forth, workspace back_and_forth
--to-code $mod+shift+q move workspace $wsq, workspace $wsq
--to-code $mod+shift+w move workspace $wsw, workspace $wsw
--to-code $mod+shift+e move workspace $wse, workspace $wse
--to-code $mod+shift+r move workspace $wsr, workspace $wsr
--to-code $mod+shift+t move workspace $wst, workspace $wst
--to-code $mod+shift+y move workspace $wsy, workspace $wsy
--to-code $mod+shift+u move workspace $wsu, workspace $wsu
--to-code $mod+shift+i move workspace $wsi, workspace $wsi
--to-code $mod+shift+o move workspace $wso, workspace $wso
--to-code $mod+shift+p move workspace $wsp, workspace $wsp
--to-code $mod+shift+bracketleft move workspace prev, workspace prev
--to-code $mod+shift+bracketright move workspace next, workspace next
$mod+shift+tab move workspace back_and_forth, workspace back_and_forth
$mod+shift+q move workspace $wsq, workspace $wsq
$mod+shift+w move workspace $wsw, workspace $wsw
$mod+shift+e move workspace $wse, workspace $wse
$mod+shift+r move workspace $wsr, workspace $wsr
$mod+shift+t move workspace $wst, workspace $wst
$mod+shift+y move workspace $wsy, workspace $wsy
$mod+shift+u move workspace $wsu, workspace $wsu
$mod+shift+i move workspace $wsi, workspace $wsi
$mod+shift+o move workspace $wso, workspace $wso
$mod+shift+p move workspace $wsp, workspace $wsp
$mod+shift+bracketleft move workspace prev, workspace prev
$mod+shift+bracketright move workspace next, workspace next
$mod+colon move scratchpad
}
@ -123,14 +123,14 @@ bindsym $mod+semicolon scratchpad show
bindsym $mod+shift+g sticky toggle
# exec
bindsym {
bindsym --to-code {
$mod+return exec footclient
$mod+shift+return exec foot
$mod+space exec fuzzel
$mod+shift+space exec "$(fuzzel -d -l 0 -p'$ ')"
$mod+slash exec xdg-open "$(find -type f | fuzzel -d -p'$ xdg-open ')"
$mod+slash exec xdg-open "$(find * -type f | fuzzel -dp'open > ')"
$mod+home exec footclient nmtui connect
$mod+shift+home exec footclient nmtui
$mod+end exec devmon -c
$mod+n exec makoctl dismiss
$mod+shift+n exec makoctl restore
print exec grim - | wl-copy
@ -138,14 +138,14 @@ bindsym {
# exec (laptop)
bindsym {
XF86AudioRaiseVolume exec wpctl set-volume @DEFAULT_AUDIO_SINK@ 1%+; exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:audio "$(wpctl get-volume @DEFAULT_AUDIO_SINK@)"
XF86AudioLowerVolume exec wpctl set-volume @DEFAULT_AUDIO_SINK@ 1%-; exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:audio "$(wpctl get-volume @DEFAULT_AUDIO_SINK@)"
XF86AudioMute exec wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle; exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:audio "$(wpctl get-volume @DEFAULT_AUDIO_SINK@)"
XF86AudioMicMute exec wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle; exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:audio "$(wpctl get-volume @DEFAULT_AUDIO_SOURCE@)"
XF86MonBrightnessUp exec brightnessctl set "+1%"; exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:brightness "Brightness: $(brightnessctl get)"
XF86MonBrightnessDown exec brightnessctl set "1%-"; exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:brightness "Brightness: $(brightnessctl get)"
shift+XF86MonBrightnessUp exec brightnessctl set "+10%"; exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:brightness "Brightness: $(brightnessctl get)"
shift+XF86MonBrightnessDown exec brightnessctl set "10%-"; exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:brightness "Brightness: $(brightnessctl get)"
XF86AudioRaiseVolume exec wpctl set-volume @DEFAULT_AUDIO_SINK@ 1%+, exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:audio "$(wpctl get-volume @DEFAULT_AUDIO_SINK@)"
XF86AudioLowerVolume exec wpctl set-volume @DEFAULT_AUDIO_SINK@ 1%-, exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:audio "$(wpctl get-volume @DEFAULT_AUDIO_SINK@)"
XF86AudioMute exec wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle, exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:audio "$(wpctl get-volume @DEFAULT_AUDIO_SINK@)"
XF86AudioMicMute exec wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle, exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:audio "$(wpctl get-volume @DEFAULT_AUDIO_SOURCE@)"
XF86MonBrightnessUp exec brightnessctl set "+1%", exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:brightness "Brightness: $(brightnessctl get)"
XF86MonBrightnessDown exec brightnessctl set "1%-", exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:brightness "Brightness: $(brightnessctl get)"
shift+XF86MonBrightnessUp exec brightnessctl set "+10%", exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:brightness "Brightness: $(brightnessctl get)"
shift+XF86MonBrightnessDown exec brightnessctl set "10%-", exec notify-send -e -t 2000 -h string:x-canonical-private-synchronous:brightness "Brightness: $(brightnessctl get)"
}
# resize
@ -157,20 +157,20 @@ bindsym {
}
# workspace
bindsym {
--to-code $mod+tab workspace back_and_forth
--to-code $mod+q workspace $wsq
--to-code $mod+w workspace $wsw
--to-code $mod+e workspace $wse
--to-code $mod+r workspace $wsr
--to-code $mod+t workspace $wst
--to-code $mod+y workspace $wsy
--to-code $mod+u workspace $wsu
--to-code $mod+i workspace $wsi
--to-code $mod+o workspace $wso
--to-code $mod+p workspace $wsp
--to-code $mod+bracketleft workspace prev
--to-code $mod+bracketright workspace next
bindsym --to-code {
$mod+tab workspace back_and_forth
$mod+q workspace $wsq
$mod+w workspace $wsw
$mod+e workspace $wse
$mod+r workspace $wsr
$mod+t workspace $wst
$mod+y workspace $wsy
$mod+u workspace $wsu
$mod+i workspace $wsi
$mod+o workspace $wso
$mod+p workspace $wsp
$mod+bracketleft workspace prev
$mod+bracketright workspace next
}
# client.* #####################################################################
@ -188,19 +188,22 @@ default_floating_border normal 0
# exec #########################################################################
exec {
systemctl --user import-environment DISPLAY WAYLAND_DISPLAY SWAYSOCK
dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK
# systemctl --user import-environment DISPLAY WAYLAND_DISPLAY SWAYSOCK
# dbus-update-activation-environment --systemd DISPLAY WAYLAND_DISPLAY SWAYSOCK
swayidle -w \
timeout 300 '$swaylock' \
timeout 600 'swaymsg "output * power off"' resume 'swaymsg "output * power on"' \
timeout 300 'brightnessctl -s set 1%' resume 'brightnessctl -r' \
timeout 600 '$swaylock' \
timeout 900 'swaymsg "output * power off"' resume 'swaymsg "output * power on"' \
timeout 1800 'systemctl suspend-then-hibernate' \
before-sleep '$swaylock'
wlsunset -l 45 -L 15
mako
devmon \
--exec-on-drive "notify-send 'Mounted %f at %d'" \
--exec-on-unmount "notify-send 'Unmounted %s'"
foot -s
}
workspace $wse
exec foot -s
# focus_wrapping ###############################################################
focus_wrapping yes
@ -231,6 +234,7 @@ mode $session_mode {
l exec $swaylock, mode default
q exit, mode default
s exec systemctl suspend, mode default
h exec systemctl hibernate, mode default
b exec systemctl reboot, mode default
p exec systemctl poweroff, mode default
escape mode default
@ -253,5 +257,3 @@ seat * hide_cursor 1000
# output #######################################################################
output * background $black solid_color
# vim: