config (7481B)
1 # SWAY is a lie. 2 # they assert it is a 'drop in' replacement for i3, but it is not. 3 4 # I experiencede lots of weird and new isses associated with tiling not 5 # correctly spacing windows after moving to sway. This is likely asscociated 6 # with my odyssey g9 as it is not a normal aspect ratio and is likely not a size 7 # that often is tested on, but it was not a good experience. 8 9 # This is why I moved to dwm. I loved i3, but I have found dwm to be better. 10 # desktop ratings by me currently: 11 # 1. DWM 12 # 2. i3 13 # 3. sway 14 # 4. Everything else 15 16 # Also, please don't use hyperland. Their animations are so slow and ugly, and it 17 # is likely taking away from real work being done to make wayland work as expected. 18 19 # Don't even get me started about the wayland screenshotting/sharing nightmare. 20 21 exec swaync 22 23 bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +5% 24 bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -5% 25 26 exec --no-startup-id feh --bg-scale /home/andrew/pictures/bg.gif 27 exec --no-startup-id /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 28 29 # Disable screen turn off inactive 30 exec xset s off 31 exec xset -dpms 32 exec xset s noblank 33 34 gaps inner 0 35 gaps outer 0 36 set $mod Mod4 37 38 # Font for window titles. Will also be used by the bar unless a different font 39 # is used in the bar {} block below. 40 font pango:Space Mono Regular 10 41 42 # This font is widely installed, provides lots of unicode glyphs, right-to-left 43 # text rendering and scalability on retina/hidpi displays (thanks to pango). 44 font pango:Inter ExtraLight 10 45 46 set $refresh_i3status killall -SIGUSR1 i3status 47 floating_modifier $mod 48 49 # start a terminal 50 bindsym $mod+Return exec foot 51 # kill focused window 52 bindsym $mod+Shift+q kill 53 54 # change focus 55 bindsym $mod+n focus left 56 bindsym $mod+e focus down 57 bindsym $mod+i focus right 58 bindsym $mod+u focus up 59 60 # alternatively, you can use the cursor keys: 61 bindsym $mod+Shift+n move left 62 bindsym $mod+Shift+e move down 63 bindsym $mod+Shift+u move up 64 bindsym $mod+Shift+i move right 65 66 # split in vertical orientation 67 bindsym $mod+v split v 68 bindsym $mod+h split h 69 # enter fullscreen mode for the focused container 70 bindsym $mod+f fullscreen toggle 71 72 # change container layout (stacked, tabbed, toggle split) 73 bindsym $mod+w layout stacking 74 75 # I never use tabbed mode so this is remapped to open dmenu for 76 # a tmux session. 77 78 # bindsym $mod+t layout tabbed 79 # I never used this. 80 # bindsym $mod+s layout toggle split 81 82 # toggle tiling / floating 83 bindsym $mod+Shift+space floating toggle 84 85 # change focus between tiling / floating windows 86 bindsym $mod+space focus mode_toggle 87 88 # focus the parent container 89 bindsym $mod+a focus parent 90 91 # focus the child container 92 #bindsym $mod+d focus child 93 94 # Define names for default workspaces for which we configure key bindings later on. 95 # We use variables to avoid repeating the names in multiple places. 96 set $ws1 "1 - Research" 97 set $ws2 "2 - LA" 98 set $ws3 "3 - COMM" 99 set $ws4 "4 - CSCI" 100 set $ws5 "5 - MATH" 101 set $ws6 "6 - ENSC" 102 set $ws7 "7 - HIST" 103 set $ws8 "8 - WRIT" 104 set $ws9 "9 - Hosting" 105 set $ws10 "10 - General" 106 107 # switch to workspace 108 bindsym $mod+1 workspace number $ws1 109 bindsym $mod+2 workspace number $ws2 110 bindsym $mod+3 workspace number $ws3 111 bindsym $mod+4 workspace number $ws4 112 bindsym $mod+5 workspace number $ws5 113 bindsym $mod+6 workspace number $ws6 114 bindsym $mod+7 workspace number $ws7 115 bindsym $mod+8 workspace number $ws8 116 bindsym $mod+9 workspace number $ws9 117 bindsym $mod+0 workspace number $ws10 118 119 # move focused container to workspace 120 bindsym $mod+Shift+1 move container to workspace number $ws1 121 bindsym $mod+Shift+2 move container to workspace number $ws2 122 bindsym $mod+Shift+3 move container to workspace number $ws3 123 bindsym $mod+Shift+4 move container to workspace number $ws4 124 bindsym $mod+Shift+5 move container to workspace number $ws5 125 bindsym $mod+Shift+6 move container to workspace number $ws6 126 bindsym $mod+Shift+7 move container to workspace number $ws7 127 bindsym $mod+Shift+8 move container to workspace number $ws8 128 bindsym $mod+Shift+9 move container to workspace number $ws9 129 bindsym $mod+Shift+0 move container to workspace number $ws10 130 131 132 # reload the configuration file 133 #bindsym $mod+Shift+c reload 134 # restart i3 inplace (preserves your layout/session, can be used to upgrade i3) 135 136 bindsym $mod+Shift+r exec "swaymsg reload" 137 138 # otherwise this is too fast without sleep 139 bindsym $mod+Shift+h exec "sleep .1 && loginctl suspend" 140 141 # save screenshot to disk (make sure directory exists) and to clipboard 142 bindsym $mod+Shift+s exec IMG=~/screenshots/$(date +%Y-%m-%d_%H-%m-%s).png && grim -g "$(slurp)" $IMG && wl-copy < $IMG 143 144 # If you just want to send it directly to clipboard 145 # bindsym $mod+Shift+s exec grim -g "$(slurp)" - | wl-copy 146 147 148 # resize window (you can also use the mouse for that) 149 mode "resize" { 150 # These bindings trigger as soon as you enter the resize mode 151 152 # Pressing left will shrink the window’s width. 153 # Pressing right will grow the window’s width. 154 # Pressing up will shrink the window’s height. 155 # Pressing down will grow the window’s height. 156 bindsym j resize shrink width 10 px or 10 ppt 157 bindsym k resize grow height 10 px or 10 ppt 158 bindsym l resize shrink height 10 px or 10 ppt 159 bindsym semicolon resize grow width 10 px or 10 ppt 160 161 # same bindings, but for the arrow keys 162 bindsym Left resize shrink width 10 px or 10 ppt 163 bindsym Down resize grow height 10 px or 10 ppt 164 bindsym Up resize shrink height 10 px or 10 ppt 165 bindsym Right resize grow width 10 px or 10 ppt 166 167 # back to normal: Enter or Escape or $mod+r 168 bindsym Return mode "default" 169 bindsym Escape mode "default" 170 bindsym $mod+r mode "default" 171 } 172 173 bindsym $mod+r mode "resize" 174 175 # Start i3bar to display a workspace bar (plus the system information i3status 176 # finds out, if available) 177 for_window [class="^.*"] border pixel 5 178 179 #LibreOffice 180 #bindsym $mod+Shift+l "exec libreoffice --writer" 181 182 # shortcuts for dmenu functions 183 184 bindsym $mod+o exec "~/bin/dmenu.sh" 185 bindsym $mod+p exec "~/bin/pass.sh" 186 bindsym $mod+t exec "~/bin/tmux.sh" 187 bindsym $mod+s exec "~/bin/search.sh" 188 bindsym $mod+z exec "~/bin/zathura.sh" 189 bindsym $mod+m exec "~/bin/find-music.sh /home/serverBackup/fileSharing/music/" 190 191 # Browsers (I don't find these very useful bc. I normally use my dmenu search) 192 193 bindsym $mod+Shift+f exec "firefox" 194 bindsym $mod+Shift+b exec "qutebrowser" 195 196 197 198 199 # class border bground text indicator child_border 200 client.focused #FFFFFF #FFFFFF #FFFFFF #BBBBBB #BBBBBB 201 client.focused_inactive #000000 #000000 #000000 #000000 #000000 202 client.unfocused #000000 #000000 #000000 #000000 #000000 203 client.urgent #000000 #000000 #000000 #000000 #000000 204 client.placeholder #000000 #000000 #000000 #000000 #000000 205 206 client.background #FFFFFF 207 208 # this runs a script to take my current clipboard and send it to mpv. This allows me to copy 209 # a youtube url and then watch it in mpv with a shortcut. 210 bindsym $mod+Shift+m exec "~/bin/mpv.sh" 211 212 bar { 213 214 position top 215 status_command i3status 216 font pango:DejaVu Sans Mono 10 217 colors { 218 background #000000 219 statusline #ffffff 220 221 focused_workspace #000000 #000000 #ffffff 222 active_workspace #6e4f9a #6e4f9a #ffffff 223 inactive_workspace #000000 #000000 #888888 224 urgent_workspace #ff6c6b #ff6c6b #ffffff 225 } 226 } 227