diff options
| author | 2026-02-11 02:44:52 +0000 | |
|---|---|---|
| committer | 2026-02-11 02:44:52 +0000 | |
| commit | 0ea7c9210869e3cbfcd3ac2aca8cbb4e18a8f832 (patch) | |
| tree | 6b9e4673a87ff4e361bd35545231ffbe92b074a6 /dot_config/sway | |
| parent | add imv (diff) | |
| download | dotfiles-0ea7c9210869e3cbfcd3ac2aca8cbb4e18a8f832.tar.gz | |
add wm
Diffstat (limited to 'dot_config/sway')
| -rw-r--r-- | dot_config/sway/config | 183 |
1 files changed, 183 insertions, 0 deletions
diff --git a/dot_config/sway/config b/dot_config/sway/config new file mode 100644 index 0000000..bdb65bd --- /dev/null +++ b/dot_config/sway/config | |||
| @@ -0,0 +1,183 @@ | |||
| 1 | xwayland enable | ||
| 2 | |||
| 3 | |||
| 4 | # Layout configuration | ||
| 5 | input * { | ||
| 6 | xkb_layout us,ru | ||
| 7 | xkb_variant altgr-intl, | ||
| 8 | xkb_options grp:shifts_toggle,ctrl:nocaps | ||
| 9 | } | ||
| 10 | |||
| 11 | |||
| 12 | # General settings: | ||
| 13 | set $mod Mod4 | ||
| 14 | floating_modifier $mod normal | ||
| 15 | bindsym --to-code $mod+Shift+r reload | ||
| 16 | |||
| 17 | |||
| 18 | # Launching external applications: | ||
| 19 | set $pass passmenu | ||
| 20 | bindsym --to-code $mod+p exec $pass -ip "Copy pass: " -l 10 | ||
| 21 | bindsym --to-code $mod+Shift+p exec $pass --name -ip "Copy name: " -l 10 | ||
| 22 | bindsym --to-code $mod+Alt+p exec $pass --type -ip "Type pass: " -l 10 | ||
| 23 | bindsym --to-code $mod+Alt+Shift+p exec $pass --type --name -ip "Type name: " -l 10 | ||
| 24 | |||
| 25 | set $power-menu powermenu -ip "Power: " | ||
| 26 | bindsym --to-code $mod+Shift+q exec $power-menu | ||
| 27 | bindsym --to-code $mod+Control+q exec $power-menu | ||
| 28 | |||
| 29 | set $term emacsclient --create-frame --quiet | ||
| 30 | set $emacs emacs --background black | ||
| 31 | set $backup-term foot | ||
| 32 | bindsym $mod+Return exec $term | ||
| 33 | bindsym $mod+Shift+Return exec $emacs | ||
| 34 | bindsym $mod+Control+Shift+Return exec $backup-term | ||
| 35 | |||
| 36 | set $menu menu-drun -ip "Run: " | ||
| 37 | set $lock lock | ||
| 38 | bindsym --to-code $mod+Shift+d exec $menu | ||
| 39 | bindsym --to-code $mod+Shift+l exec $lock | ||
| 40 | bindsym --to-code $mod+Control+d exec $menu | ||
| 41 | bindsym --to-code $mod+Control+l exec $lock | ||
| 42 | |||
| 43 | bindsym --to-code $mod+Control+n exec menu-network | ||
| 44 | |||
| 45 | |||
| 46 | # Manipulating windows: | ||
| 47 | bindsym --to-code $mod+Shift+c kill | ||
| 48 | bindsym --to-code $mod+Shift+f fullscreen | ||
| 49 | bindsym --to-code $mod+Control+c kill | ||
| 50 | |||
| 51 | bindsym $mod+Shift+space floating toggle | ||
| 52 | bindsym $mod+Ctrl+space focus mode_toggle | ||
| 53 | |||
| 54 | bindsym $mod+Left focus left | ||
| 55 | bindsym $mod+Down focus down | ||
| 56 | bindsym $mod+Up focus up | ||
| 57 | bindsym $mod+Right focus right | ||
| 58 | |||
| 59 | bindsym $mod+Shift+Left move left | ||
| 60 | bindsym $mod+Shift+Down move down | ||
| 61 | bindsym $mod+Shift+Up move up | ||
| 62 | bindsym $mod+Shift+Right move right | ||
| 63 | |||
| 64 | bindsym $mod+Control+b focus left | ||
| 65 | bindsym $mod+Control+n focus down | ||
| 66 | bindsym $mod+Control+p focus up | ||
| 67 | bindsym $mod+Control+f focus right | ||
| 68 | |||
| 69 | bindsym $mod+Control+Shift+b move left | ||
| 70 | bindsym $mod+Control+Shift+n move down | ||
| 71 | bindsym $mod+Control+Shift+p move up | ||
| 72 | bindsym $mod+Control+Shift+f move right | ||
| 73 | |||
| 74 | |||
| 75 | # Moving around workspaces: | ||
| 76 | |||
| 77 | bindsym $mod+tab workspace back_and_forth | ||
| 78 | bindsym $mod+Control+i workspace back_and_forth | ||
| 79 | |||
| 80 | bindsym $mod+1 workspace number 1 | ||
| 81 | bindsym $mod+2 workspace number 2 | ||
| 82 | bindsym $mod+3 workspace number 3 | ||
| 83 | bindsym $mod+4 workspace number 4 | ||
| 84 | bindsym $mod+5 workspace number 5 | ||
| 85 | bindsym $mod+6 workspace number 6 | ||
| 86 | bindsym $mod+7 workspace number 7 | ||
| 87 | bindsym $mod+8 workspace number 8 | ||
| 88 | bindsym $mod+9 workspace number 9 | ||
| 89 | bindsym $mod+0 workspace number 10 | ||
| 90 | |||
| 91 | bindsym $mod+Shift+1 move container to workspace number 1 | ||
| 92 | bindsym $mod+Shift+2 move container to workspace number 2 | ||
| 93 | bindsym $mod+Shift+3 move container to workspace number 3 | ||
| 94 | bindsym $mod+Shift+4 move container to workspace number 4 | ||
| 95 | bindsym $mod+Shift+5 move container to workspace number 5 | ||
| 96 | bindsym $mod+Shift+6 move container to workspace number 6 | ||
| 97 | bindsym $mod+Shift+7 move container to workspace number 7 | ||
| 98 | bindsym $mod+Shift+8 move container to workspace number 8 | ||
| 99 | bindsym $mod+Shift+9 move container to workspace number 9 | ||
| 100 | bindsym $mod+Shift+0 move container to workspace number 10 | ||
| 101 | |||
| 102 | |||
| 103 | # Scratchpad settings: | ||
| 104 | bindsym --to-code $mod+Shift+minus move scratchpad | ||
| 105 | bindsym --to-code $mod+minus scratchpad show | ||
| 106 | |||
| 107 | |||
| 108 | # Other: | ||
| 109 | |||
| 110 | bindsym $mod+Control+t exec emacsclient -e "(modus-themes-toggle)" | ||
| 111 | |||
| 112 | default_border pixel | ||
| 113 | default_floating_border pixel | ||
| 114 | gaps inner 4 | ||
| 115 | exec gpg-connect-agent updatestartuptty /bye >/dev/null | ||
| 116 | # exec pipewire | ||
| 117 | exec --no-startup-id udiskie -s | ||
| 118 | exec --no-startup-id $emacs | ||
| 119 | exec --no-startup-id swayidle -w | ||
| 120 | exec_always --no-startup-id mako | ||
| 121 | |||
| 122 | # toggle waybar | ||
| 123 | # bindsym $mod+o exec killall -SIGUSR1 waybar | ||
| 124 | |||
| 125 | bindsym --locked XF86AudioRaiseVolume \ | ||
| 126 | exec pactl set-sink-mute @DEFAULT_SINK@ false; \ | ||
| 127 | exec pactl set-sink-volume @DEFAULT_SINK@ +5% | ||
| 128 | bindsym --locked XF86AudioLowerVolume \ | ||
| 129 | exec pactl set-sink-mute @DEFAULT_SINK@ false; \ | ||
| 130 | exec pactl set-sink-volume @DEFAULT_SINK@ -5% | ||
| 131 | bindsym --locked XF86AudioMute exec pactl set-sink-mute @DEFAULT_SINK@ toggle | ||
| 132 | bindsym --locked XF86AudioMicMute \ | ||
| 133 | exec pactl set-source-mute @DEFAULT_SOURCE@ toggle | ||
| 134 | bindsym --locked XF86MonBrightnessUp exec brightnessctl set 5%+ | ||
| 135 | bindsym --locked XF86MonBrightnessDown exec brightnessctl set 5%- | ||
| 136 | |||
| 137 | output LVDS-1 pos 0 0 res 1366x768 | ||
| 138 | output VGA-1 pos 1366 0 res 1024x768 | ||
| 139 | # output * adaptive_sync on # this may be good, test it | ||
| 140 | bindswitch --reload --locked lid:on exec swaylock | ||
| 141 | bindsym $mod+Shift+o [floating] kill | ||
| 142 | input 6700:66:SEMICCHIP_Usb_Mouse { | ||
| 143 | pointer_accel 0.0 | ||
| 144 | accel_profile flat | ||
| 145 | } | ||
| 146 | input 6127:24647:Lenovo_ThinkPad_Compact_USB_Keyboard_with_TrackPoint { | ||
| 147 | pointer_accel -0.6 | ||
| 148 | repeat_delay 150 | ||
| 149 | repeat_rate 60 | ||
| 150 | } | ||
| 151 | input type:keyboard { | ||
| 152 | repeat_delay 150 | ||
| 153 | repeat_rate 60 | ||
| 154 | } | ||
| 155 | input type:touchpad { | ||
| 156 | natural_scroll enabled | ||
| 157 | tap enabled | ||
| 158 | } | ||
| 159 | |||
| 160 | bindsym $mod+Alt+s exec sway-swappy-clipboard | ||
| 161 | bindsym $mod+Shift+s exec sway-shot-window-or-selection | ||
| 162 | |||
| 163 | bindsym $mod+Print exec sway-shot-output | ||
| 164 | bindsym $mod+Alt+Print exec sway-swappy-clipboard | ||
| 165 | bindsym XF86SelectiveScreenshot exec sway-shot-window-or-selection | ||
| 166 | bindsym $mod+Shift+Print exec sway-shot-window-or-selection | ||
| 167 | bindsym $mod+Control+Print exec toggle-screen-capture output | ||
| 168 | bindsym $mod+Shift+Control+Print exec toggle-screen-capture window | ||
| 169 | |||
| 170 | bindsym $mod+Control+s exec spotlight | ||
| 171 | |||
| 172 | # bindsym --to-code XF86NotificationCenter exec toggle dunst | ||
| 173 | |||
| 174 | bar swaybar_command waybar | ||
| 175 | |||
| 176 | for_window [title=".* - Emacs Client"] floating enable | ||
| 177 | for_window [title="cmatrix"] floating enable | ||
| 178 | for_window [app_id="wdisplays"] floating enable | ||
| 179 | for_window [app_id="iwgtk"] floating enable | ||
| 180 | for_window [app_id="mpv"] floating enable | ||
| 181 | |||
| 182 | smart_borders on | ||
| 183 | smart_gaps on | ||
