Skip to content

Instantly share code, notes, and snippets.

@odkr
Created June 29, 2025 15:09
Show Gist options
  • Save odkr/58b8e7383fe7c20921827842571884ea to your computer and use it in GitHub Desktop.
Save odkr/58b8e7383fe7c20921827842571884ea to your computer and use it in GitHub Desktop.
set $mod Mod4
set $left h
set $down j
set $up k
set $right l
set $term exec ghostty
set $menu exec fuzzel
input type:keyboard {
xkb_layout de
xkb_numlock enabled
}
input 1:1:AT_Translated_Set_2_keyboard {
xkb_numlock disabled
}
input type:touchpad {
natural_scroll enabled
scroll_method two_finger
tap disabled
}
output "*" {
background /usr/local/share/backgrounds/polar-gradient.jpg fill
}
output DP-1 {
scale 2
}
output eDP-1 {
background /usr/local/share/backgrounds/neon-gradient.jpg fill
}
seat seat0 xcursor_theme Adwaita 24
exec dbus-update-activation-environment \
DISPLAY \
WAYLAND_DISPLAY \
XCURSOR_SIZE \
XCURSOR_THEME \
XDG_CONFIG_HOME \
XDG_CURRENT_DESKTOP \
XDG_DATA_DIRS \
XDG_RUNTIME_DIR \
XDG_SEAT \
XDG_SESSION_DESKTOP \
XDG_SESSION_TYPE \
XDG_VTNR
exec swayidle \
timeout 180 '~/.local/bin/locksway' \
timeout 600 'sudo zzz'
bindsym $mod+alt+l exec '~/.local/bin/locksway'
bindsym $mod+Return exec $term
bindsym $mod+Shift+q kill
bindsym $mod+d exec $menu
floating_modifier $mod normal
bindsym $mod+Shift+c reload
bindsym $mod+Shift+e exec swaynag -t warning \
-m 'What do you want to do?' \
-B 'Exit' 'dinitctl stop sway; swaymsg exit' \
-B 'Reboot' 'sudo reboot' \
-B 'Power off' 'sudo poweroff'
bindsym $mod+Shift+s exec swaynag -t warning \
-m 'What do you want to do?' \
-B 'Hibernate' 'locksway -r1 | ( read -r _; sudo zzz -Z )' \
-B 'Suspend' 'locksway -r1 | ( read -r _; sudo zzz )'
bindsym $mod+$left focus left
bindsym $mod+$down focus down
bindsym $mod+$up focus up
bindsym $mod+$right focus right
bindsym $mod+Left focus left
bindsym $mod+Down focus down
bindsym $mod+Up focus up
bindsym $mod+Right focus right
bindsym $mod+Shift+$left move left
bindsym $mod+Shift+$down move down
bindsym $mod+Shift+$up move up
bindsym $mod+Shift+$right move right
bindsym $mod+Shift+Left move left
bindsym $mod+Shift+Down move down
bindsym $mod+Shift+Up move up
bindsym $mod+Shift+Right move right
bindsym $mod+1 workspace number 1
bindsym $mod+2 workspace number 2
bindsym $mod+3 workspace number 3
bindsym $mod+4 workspace number 4
bindsym $mod+5 workspace number 5
bindsym $mod+6 workspace number 6
bindsym $mod+7 workspace number 7
bindsym $mod+8 workspace number 8
bindsym $mod+9 workspace number 9
bindsym $mod+0 workspace number 10
bindsym $mod+Shift+1 move container to workspace number 1
bindsym $mod+Shift+2 move container to workspace number 2
bindsym $mod+Shift+3 move container to workspace number 3
bindsym $mod+Shift+4 move container to workspace number 4
bindsym $mod+Shift+5 move container to workspace number 5
bindsym $mod+Shift+6 move container to workspace number 6
bindsym $mod+Shift+7 move container to workspace number 7
bindsym $mod+Shift+8 move container to workspace number 8
bindsym $mod+Shift+9 move container to workspace number 9
bindsym $mod+Shift+0 move container to workspace number 10
bindsym $mod+b splith
bindsym $mod+v splitv
bindsym $mod+s layout stacking
bindsym $mod+w layout tabbed
bindsym $mod+e layout toggle split
bindsym $mod+f fullscreen
bindsym $mod+Shift+space floating toggle
bindsym $mod+space focus mode_toggle
bindsym $mod+a focus parent
bindsym $mod+Shift+minus move scratchpad
bindsym $mod+minus scratchpad show
mode "resize" {
bindsym $left resize shrink width 10px
bindsym $down resize grow height 10px
bindsym $up resize shrink height 10px
bindsym $right resize grow width 10px
bindsym Left resize shrink width 10px
bindsym Down resize grow height 10px
bindsym Up resize shrink height 10px
bindsym Right resize grow width 10px
bindsym Return mode "default"
bindsym Escape mode "default"
}
bindsym $mod+r mode "resize"
bindsym --locked XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle
bindsym --locked XF86AudioLowerVolume exec pactl set-sink-volume @DEFAULT_SINK@ -5%
bindsym --locked XF86AudioRaiseVolume exec pactl set-sink-volume @DEFAULT_SINK@ +5%
bindsym --locked XF86AudioMicMute exec pactl set-source-mute @DEFAULT_SOURCE@ toggle
bindsym --locked XF86MonBrightnessDown exec brightnessctl set 5%-
bindsym --locked XF86MonBrightnessUp exec brightnessctl set 5%+
bindsym Print exec grimshot save output
bindsym Shift+Print exec grimshot save window
bindsym Alt+Print exec grimshot save area
bindgesture swipe:3:right workspace prev
bindgesture swipe:3:left workspace next
for_window {
[window_role="pop-up"] floating enable
[window_role="bubble"] floating enable
[window_role="dialog"] floating enable
[window_type="dialog"] floating enable
}
font pango:Roboto 11
hide_edge_borders none
default_border pixel 1
gaps outer 4
gaps inner 4
blur disable
blur_brightness 1.1
blur_saturation 2
corner_radius 6
shadows enable
set $nord0 #2e3440
set $nord1 #3b4252
set $nord6 #eceff4
set $nord8 #88c0d0
set $nord9 #81a1c1
set $nord10 #5e81ac
client.focused $nord8 $nord8 $nord0
client.focused_inactive $nord10 $nord10 $nord6
client.unfocused $nord1 $nord1 $nord6
client.focused_tab_title $nord9 $nord9 $nord6
for_window {
[app_id="firefox"] inhibit_idle fullscreen
[title="^(Picture-in-Picture|Bild-im-Bild)$"] {
floating enable
resize set 25 ppt 25 ppt
sticky enable
border none
}
}
for_window [app_id="com.mitchellh.ghostty"] {
blur enable
}
for_window [app_id="org.keepassxc.KeePassXC"] {
floating enable
}
layer_effects "notifications" {
blur enable
blur_ignore_transparent enable
}
for_window [app_id="com.nextcloud.desktopclient.nextcloud"] {
border none
blur disable
shadows disable
}
for_window [app_id="^nm-"] {
floating enable
}
for_window [app_id="org.pulseaudio.pavucontrol"] {
floating enable
}
layer_effects "waybar" {
blur enable
blur_brightness 1.1
blur_saturation 2
}
exec dinitctl setenv \
DISPLAY \
WAYLAND_DISPLAY \
XDG_CONFIG_HOME \
XDG_CURRENT_DESKTOP \
XDG_DATA_DIRS \
XDG_RUNTIME_DIR \
XDG_SEAT \
XDG_SESSION_DESKTOP \
XDG_SESSION_TYPE \
XDG_VTNR \
LIBSEAT_BACKEND \
XCURSOR_SIZE \
XCURSOR_THEME \
I3SOCK \
SWAYSOCK \
SSH_AUTH_SOCK
exec dinitctl start sway
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment