aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYaroslav de la Peña Smirnov <yps@yaroslavps.com>2020-12-14 00:34:19 +0300
committerYaroslav de la Peña Smirnov <yps@yaroslavps.com>2020-12-14 00:34:19 +0300
commit351ad45e9fdd98d2eef4b87173c32084b2db7c27 (patch)
tree29ec7a91f95d2072e971792352b0d758d04a011f
parente87df82bc71e38e77a3bd768d802ecd57a0e9ffb (diff)
downloadswayrice-351ad45e9fdd98d2eef4b87173c32084b2db7c27.tar.gz
swayrice-351ad45e9fdd98d2eef4b87173c32084b2db7c27.zip
Changes to sway config
* Use hard tabs for indentation. * Shortcuts for more precise control of keyboard layout.
-rw-r--r--dotfiles/.config/sway/config491
1 files changed, 248 insertions, 243 deletions
diff --git a/dotfiles/.config/sway/config b/dotfiles/.config/sway/config
index 116a0fc..6a08d03 100644
--- a/dotfiles/.config/sway/config
+++ b/dotfiles/.config/sway/config
@@ -41,8 +41,8 @@ floating_modifier $mod
# GTK theme and icons
set $gnome-schema org.gnome.desktop.interface
exec_always {
- gsettings set $gnome-schema gtk-theme 'oomox-materia-dark'
- gsettings set $gnome-schema icon-theme 'Papirus-Dark'
+ gsettings set $gnome-schema gtk-theme 'oomox-materia-dark'
+ gsettings set $gnome-schema icon-theme 'Papirus-Dark'
}
##### Startup scripts and programs #####
@@ -120,8 +120,8 @@ output "HDMI-A-2" pos 1920 200
# Keymaps
input type:keyboard {
- xkb_layout "us,es,ru"
- xkb_options "lv3:ralt_switch,grp:alt_shift_toggle,misc:typo,caps:escape,grp_led:scroll"
+ xkb_layout "us,es,ru"
+ xkb_options "lv3:ralt_switch,grp:alt_shift_toggle,misc:typo,caps:escape,grp_led:scroll"
}
# Set inner/outer gaps
@@ -138,245 +138,250 @@ smart_borders no_gaps
##### Bindsyms (layout-independent) #####
bindsym --to-code {
- # start a terminal
- $mod+Return exec $term
-
- # kill focused window
- $mod+Shift+q kill
- $mod+q kill
-
- # bemenu program launcher (-x force run through xwayland, -t run in terminal)
- $mod+d exec --no-startup-id menurun
- $mod+Shift+d exec --no-startup-id "menurun -t"
- $mod+Ctrl+d exec --no-startup-id "menurun -x"
-
- # Mako (notifications)
- $mod+Ctrl+space exec "makoctl dismiss"
- $mod+Ctrl+Shift+space exec "makoctl restore"
-
- # Screen brightness controls
- XF86MonBrightnessUp exec "xbacklight -inc 5"
- XF86MonBrightnessDown exec "xbacklight -dec 5"
- $mod+Ctrl+Up exec "xbacklight -inc 5"
- $mod+Ctrl+Down exec "xbacklight -dec 5"
-
- # Media keys
- XF86AudioPrev exec --no-startup-id "lmc prev"
- XF86AudioPlay exec --no-startup-id "lmc toggle"
- XF86AudioNext exec --no-startup-id "lmc next"
- XF86AudioRaiseVolume exec --no-startup-id lmc up 5
- XF86AudioLowerVolume exec --no-startup-id lmc down 5
- XF86AudioMute exec --no-startup-id lmc mute
-
- $mod+Shift+F5 exec mpc seek -10
- $mod+F5 exec lmc prev
- $mod+F6 exec lmc toggle
- $mod+F7 exec lmc next
- $mod+Shift+F7 exec mpc seek +10
- $mod+F8 exec mpc single
- $mod+Shift+F8 exec mpc repeat
-
- # Start Applications
- $mod+Shift+w exec --no-startup-id $browser
- $mod+Ctrl+w exec --no-startup-id chromium
- $mod+F1 exec menuman
- $mod+F2 exec menumako
- $mod+F3 exec menudisplay
- $mod+F4 exec menublk
- $mod+F10 exec chcolors
- $mod+F12 exec menutz
- $mod+r exec $term -t "ranger" -e ranger
- $mod+t exec --no-startup-id toggletorrent
- $mod+Ctrl+t exec --no-startup-id launch-transmission
- $mod+s exec "xway steam"
- $mod+m exec $term -e ncmpcpp
- $mod+n exec $term -t "newsboat" -e newsboat && killall -42 waybar
- $mod+a exec $term -t "aerc" -e aerc
- $mod+o exec --no-startup-id notistats
- $mod+c exec --no-startup-id camtoggle
- $mod+grave exec --no-startup-id menuemoji
- $mod+Ctrl+grave exec --no-startup-id menuwebsurf
- $mod+Shift+grave exec --no-startup-id menuwebsurf paste
- $mod+apostrophe exec --no-startup-id menupass
- $mod+Shift+apostrophe exec --no-startup-id "menupass -l"
- $mod+Ctrl+apostrophe exec --no-startup-id "menupass -f"
- $mod+Ctrl+Shift+apostrophe exec --no-startup-id "menupass -s"
-
- # Network management
- $mod+Shift+c exec togglevpn
- $mod+Shift+n exec $term -t "Network Manager" -e 'nmtui'
-
- # Screenshot and recording
- Print exec --no-startup-id menugrim -q
- $mod+Print exec --no-startup-id menugrim
- Shift+Print exec --no-startup-id "swayrecord screencast"
- Ctrl+Print exec --no-startup-id swayrecord
-
- # Sound
- $mod+Shift+m exec $term -t "ncpamixer" -e 'ncpamixer'
- $mod+Ctrl+m exec --no-startup-id menuoutput
-
- # Applications that start with no gaps
- $mod+g exec --no-startup-id gimp; gaps inner current set 0; gaps outer current set 0
- $mod+i exec --no-startup-id inkscape; gaps inner current set 0; gaps outer current set 0
-
- # Dropdown/scratchpad applications
- $mod+Shift+v exec --no-startup-id ddvk
- $mod+Shift+t exec --no-startup-id ddtelegram
- $mod+Shift+p exec --no-startup-id ddquakemite
-
- # Sticky float to a bottom corner
- $mod+Shift+b floating toggle; sticky toggle; exec --no-startup-id picinpic
- $mod+Ctrl+b floating toggle; sticky toggle; exec --no-startup-id picinpic left
-
- # change focus
- $mod+h focus left
- $mod+j focus down
- $mod+k focus up
- $mod+l focus right
- $mod+z focus parent
- $mod+shift+z focus child
-
- # alternatively, you can use the cursor keys:
- $mod+Left focus left
- $mod+Down focus down
- $mod+Up focus up
- $mod+Right focus right
-
- # move focused window
- $mod+Shift+h move left
- $mod+Shift+j move down
- $mod+Shift+k move up
- $mod+Shift+l move right
-
- # alternatively, you can use the cursor keys:
- $mod+Shift+Left move left
- $mod+Shift+Down move down
- $mod+Shift+Up move up
- $mod+Shift+Right move right
-
- # split orientation
- $mod+b split h
- $mod+v split v
-
- # toggle fullscreen mode for the focused container
- $mod+f fullscreen toggle
-
- # change container layout (stacked, tabbed, toggle split)
- $mod+slash layout stacking
- $mod+w layout tabbed
- $mod+e layout toggle split
-
- # toggle tiling / floating
- $mod+Shift+space floating toggle
-
- # change focus between tiling / floating windows
- $mod+space focus mode_toggle
-
- # toggle sticky
- $mod+Shift+s sticky toggle
-
- # move the currently focused window to the scratchpad
- $mod+Shift+minus move scratchpad
-
- # Show the next scratchpad window or hide the focused scratchpad window.
- # If there are multiple scratchpad windows, this command cycles through them.
- $mod+minus scratchpad show
-
- #navigate workspaces next / previous
- $mod+Tab workspace next
- $mod+Shift+Tab workspace prev
-
- # switch to workspace
- $mod+1 workspace $ws1
- $mod+2 workspace $ws2
- $mod+3 workspace $ws3
- $mod+4 workspace $ws4
- $mod+5 workspace $ws5
- $mod+6 workspace $ws6
- $mod+7 workspace $ws7
- $mod+8 workspace $ws8
- $mod+9 workspace $ws9
- $mod+0 workspace $ws10
-
- # Move focused container to workspace
- $mod+Ctrl+1 move container to workspace $ws1
- $mod+Ctrl+2 move container to workspace $ws2
- $mod+Ctrl+3 move container to workspace $ws3
- $mod+Ctrl+4 move container to workspace $ws4
- $mod+Ctrl+5 move container to workspace $ws5
- $mod+Ctrl+6 move container to workspace $ws6
- $mod+Ctrl+7 move container to workspace $ws7
- $mod+Ctrl+8 move container to workspace $ws8
- $mod+Ctrl+9 move container to workspace $ws9
- $mod+Ctrl+0 move container to workspace $ws10
-
- # Move to workspace with focused container
- $mod+Shift+1 move container to workspace $ws1; workspace $ws1
- $mod+Shift+2 move container to workspace $ws2; workspace $ws2
- $mod+Shift+3 move container to workspace $ws3; workspace $ws3
- $mod+Shift+4 move container to workspace $ws4; workspace $ws4
- $mod+Shift+5 move container to workspace $ws5; workspace $ws5
- $mod+Shift+6 move container to workspace $ws6; workspace $ws6
- $mod+Shift+7 move container to workspace $ws7; workspace $ws7
- $mod+Shift+8 move container to workspace $ws8; workspace $ws8
- $mod+Shift+9 move container to workspace $ws9; workspace $ws9
- $mod+Shift+0 move container to workspace $ws10; workspace $ws10
-
- # reload the configuration file
- $mod+Shift+r reload
-
- # restart waybar
- $mod+Ctrl+r exec --no-startup-id waybar_launch
-
- # show/hide waybar
- $mod+F11 exec --no-startup-id "killall -10 waybar"
-
- # Shut down, restart and locking features
- $mod+Shift+e exec menusession
-
- # Resize
- $mod+Shift+y exec --no-startup-id swayresize left
- $mod+Shift+u exec --no-startup-id swayresize down
- $mod+Shift+i exec --no-startup-id swayresize up
- $mod+Shift+o exec --no-startup-id swayresize right
- $mod+Ctrl+y exec --no-startup-id swayresize left 10
- $mod+Ctrl+u exec --no-startup-id swayresize down 10
- $mod+Ctrl+i exec --no-startup-id swayresize up 10
- $mod+Ctrl+o exec --no-startup-id swayresize right 10
-
- # Lock screen
- $mod+x exec --no-startup-id lock-color
- $mod+Shift+x exec --no-startup-id lock-color screenon
-
- # Gaps
- $mod+semicolon gaps inner current set 15; gaps outer current set 0
- $mod+Shift+semicolon gaps inner current set 0; gaps outer current set 0
- $mod+Ctrl+semicolon gaps inner current set 45; gaps outer current set 15
- $mod+period gaps outer current plus 5
- $mod+Shift+period gaps outer current minus 5
- $mod+comma gaps inner current plus 5
- $mod+Shift+comma gaps inner current minus 5
-
- #### Shortcuts to control my other computer through ssh ####
-
- # Media keys
- $mod+XF86AudioPrev exec --no-startup-id exremote "lmc prev"
- $mod+XF86AudioPlay exec --no-startup-id exremote "lmc toggle"
- $mod+XF86AudioNext exec --no-startup-id exremote "lmc next"
- $mod+XF86AudioRaiseVolume exec --no-startup-id exremote "lmc up 5"
- $mod+XF86AudioLowerVolume exec --no-startup-id exremote "lmc down 5"
- $mod+XF86AudioMute exec --no-startup-id exremote "lmc mute"
-
- $mod+Ctrl+Shift+F5 exec exremote "mpc seek -10"
- $mod+Ctrl+F5 exec exremote "lmc prev"
- $mod+Ctrl+F6 exec exremote "lmc toggle"
- $mod+Ctrl+F7 exec exremote "lmc next"
- $mod+Ctrl+Shift+F7 exec exremote "mpc seek +10"
-
- # Remote computer's clipboard
- $mod+Ctrl+c exec clipremote copy
- $mod+Ctrl+v exec clipremote paste
+ # Switch to specific keyboard layout
+ $mod+Alt+1 input type:keyboard xkb_switch_layout 0
+ $mod+Alt+2 input type:keyboard xkb_switch_layout 1
+ $mod+Alt+3 input type:keyboard xkb_switch_layout 2
+
+ # start a terminal
+ $mod+Return exec $term
+
+ # kill focused window
+ $mod+Shift+q kill
+ $mod+q kill
+
+ # bemenu program launcher (-x force run through xwayland, -t run in terminal)
+ $mod+d exec --no-startup-id menurun
+ $mod+Shift+d exec --no-startup-id "menurun -t"
+ $mod+Ctrl+d exec --no-startup-id "menurun -x"
+
+ # Mako (notifications)
+ $mod+Ctrl+space exec "makoctl dismiss"
+ $mod+Ctrl+Shift+space exec "makoctl restore"
+
+ # Screen brightness controls
+ XF86MonBrightnessUp exec "xbacklight -inc 5"
+ XF86MonBrightnessDown exec "xbacklight -dec 5"
+ $mod+Ctrl+Up exec "xbacklight -inc 5"
+ $mod+Ctrl+Down exec "xbacklight -dec 5"
+
+ # Media keys
+ XF86AudioPrev exec --no-startup-id "lmc prev"
+ XF86AudioPlay exec --no-startup-id "lmc toggle"
+ XF86AudioNext exec --no-startup-id "lmc next"
+ XF86AudioRaiseVolume exec --no-startup-id lmc up 5
+ XF86AudioLowerVolume exec --no-startup-id lmc down 5
+ XF86AudioMute exec --no-startup-id lmc mute
+
+ $mod+Shift+F5 exec mpc seek -10
+ $mod+F5 exec lmc prev
+ $mod+F6 exec lmc toggle
+ $mod+F7 exec lmc next
+ $mod+Shift+F7 exec mpc seek +10
+ $mod+F8 exec mpc single
+ $mod+Shift+F8 exec mpc repeat
+
+ # Start Applications
+ $mod+Shift+w exec --no-startup-id $browser
+ $mod+Ctrl+w exec --no-startup-id chromium
+ $mod+F1 exec menuman
+ $mod+F2 exec menumako
+ $mod+F3 exec menudisplay
+ $mod+F4 exec menublk
+ $mod+F10 exec chcolors
+ $mod+F12 exec menutz
+ $mod+r exec $term -t "ranger" -e ranger
+ $mod+t exec --no-startup-id toggletorrent
+ $mod+Ctrl+t exec --no-startup-id launch-transmission
+ $mod+s exec "xway steam"
+ $mod+m exec $term -e ncmpcpp
+ $mod+n exec $term -t "newsboat" -e newsboat && killall -42 waybar
+ $mod+a exec $term -t "aerc" -e aerc
+ $mod+o exec --no-startup-id notistats
+ $mod+c exec --no-startup-id camtoggle
+ $mod+grave exec --no-startup-id menuemoji
+ $mod+Ctrl+grave exec --no-startup-id menuwebsurf
+ $mod+Shift+grave exec --no-startup-id menuwebsurf paste
+ $mod+apostrophe exec --no-startup-id menupass
+ $mod+Shift+apostrophe exec --no-startup-id "menupass -l"
+ $mod+Ctrl+apostrophe exec --no-startup-id "menupass -f"
+ $mod+Ctrl+Shift+apostrophe exec --no-startup-id "menupass -s"
+
+ # Network management
+ $mod+Shift+c exec togglevpn
+ $mod+Shift+n exec $term -t "Network Manager" -e 'nmtui'
+
+ # Screenshot and recording
+ Print exec --no-startup-id menugrim -q
+ $mod+Print exec --no-startup-id menugrim
+ Shift+Print exec --no-startup-id "swayrecord screencast"
+ Ctrl+Print exec --no-startup-id swayrecord
+
+ # Sound
+ $mod+Shift+m exec $term -t "ncpamixer" -e 'ncpamixer'
+ $mod+Ctrl+m exec --no-startup-id menuoutput
+
+ # Applications that start with no gaps
+ $mod+g exec --no-startup-id gimp; gaps inner current set 0; gaps outer current set 0
+ $mod+i exec --no-startup-id inkscape; gaps inner current set 0; gaps outer current set 0
+
+ # Dropdown/scratchpad applications
+ $mod+Shift+v exec --no-startup-id ddvk
+ $mod+Shift+t exec --no-startup-id ddtelegram
+ $mod+Shift+p exec --no-startup-id ddquakemite
+
+ # Sticky float to a bottom corner
+ $mod+Shift+b floating toggle; sticky toggle; exec --no-startup-id picinpic
+ $mod+Ctrl+b floating toggle; sticky toggle; exec --no-startup-id picinpic left
+
+ # change focus
+ $mod+h focus left
+ $mod+j focus down
+ $mod+k focus up
+ $mod+l focus right
+ $mod+z focus parent
+ $mod+shift+z focus child
+
+ # alternatively, you can use the cursor keys:
+ $mod+Left focus left
+ $mod+Down focus down
+ $mod+Up focus up
+ $mod+Right focus right
+
+ # move focused window
+ $mod+Shift+h move left
+ $mod+Shift+j move down
+ $mod+Shift+k move up
+ $mod+Shift+l move right
+
+ # alternatively, you can use the cursor keys:
+ $mod+Shift+Left move left
+ $mod+Shift+Down move down
+ $mod+Shift+Up move up
+ $mod+Shift+Right move right
+
+ # split orientation
+ $mod+b split h
+ $mod+v split v
+
+ # toggle fullscreen mode for the focused container
+ $mod+f fullscreen toggle
+
+ # change container layout (stacked, tabbed, toggle split)
+ $mod+slash layout stacking
+ $mod+w layout tabbed
+ $mod+e layout toggle split
+
+ # toggle tiling / floating
+ $mod+Shift+space floating toggle
+
+ # change focus between tiling / floating windows
+ $mod+space focus mode_toggle
+
+ # toggle sticky
+ $mod+Shift+s sticky toggle
+
+ # move the currently focused window to the scratchpad
+ $mod+Shift+minus move scratchpad
+
+ # Show the next scratchpad window or hide the focused scratchpad window.
+ # If there are multiple scratchpad windows, this command cycles through them.
+ $mod+minus scratchpad show
+
+ #navigate workspaces next / previous
+ $mod+Tab workspace next
+ $mod+Shift+Tab workspace prev
+
+ # switch to workspace
+ $mod+1 workspace $ws1
+ $mod+2 workspace $ws2
+ $mod+3 workspace $ws3
+ $mod+4 workspace $ws4
+ $mod+5 workspace $ws5
+ $mod+6 workspace $ws6
+ $mod+7 workspace $ws7
+ $mod+8 workspace $ws8
+ $mod+9 workspace $ws9
+ $mod+0 workspace $ws10
+
+ # Move focused container to workspace
+ $mod+Ctrl+1 move container to workspace $ws1
+ $mod+Ctrl+2 move container to workspace $ws2
+ $mod+Ctrl+3 move container to workspace $ws3
+ $mod+Ctrl+4 move container to workspace $ws4
+ $mod+Ctrl+5 move container to workspace $ws5
+ $mod+Ctrl+6 move container to workspace $ws6
+ $mod+Ctrl+7 move container to workspace $ws7
+ $mod+Ctrl+8 move container to workspace $ws8
+ $mod+Ctrl+9 move container to workspace $ws9
+ $mod+Ctrl+0 move container to workspace $ws10
+
+ # Move to workspace with focused container
+ $mod+Shift+1 move container to workspace $ws1; workspace $ws1
+ $mod+Shift+2 move container to workspace $ws2; workspace $ws2
+ $mod+Shift+3 move container to workspace $ws3; workspace $ws3
+ $mod+Shift+4 move container to workspace $ws4; workspace $ws4
+ $mod+Shift+5 move container to workspace $ws5; workspace $ws5
+ $mod+Shift+6 move container to workspace $ws6; workspace $ws6
+ $mod+Shift+7 move container to workspace $ws7; workspace $ws7
+ $mod+Shift+8 move container to workspace $ws8; workspace $ws8
+ $mod+Shift+9 move container to workspace $ws9; workspace $ws9
+ $mod+Shift+0 move container to workspace $ws10; workspace $ws10
+
+ # reload the configuration file
+ $mod+Shift+r reload
+
+ # restart waybar
+ $mod+Ctrl+r exec --no-startup-id waybar_launch
+
+ # show/hide waybar
+ $mod+F11 exec --no-startup-id "killall -10 waybar"
+
+ # Shut down, restart and locking features
+ $mod+Shift+e exec menusession
+
+ # Resize
+ $mod+Shift+y exec --no-startup-id swayresize left
+ $mod+Shift+u exec --no-startup-id swayresize down
+ $mod+Shift+i exec --no-startup-id swayresize up
+ $mod+Shift+o exec --no-startup-id swayresize right
+ $mod+Ctrl+y exec --no-startup-id swayresize left 10
+ $mod+Ctrl+u exec --no-startup-id swayresize down 10
+ $mod+Ctrl+i exec --no-startup-id swayresize up 10
+ $mod+Ctrl+o exec --no-startup-id swayresize right 10
+
+ # Lock screen
+ $mod+x exec --no-startup-id lock-color
+ $mod+Shift+x exec --no-startup-id lock-color screenon
+
+ # Gaps
+ $mod+semicolon gaps inner current set 15; gaps outer current set 0
+ $mod+Shift+semicolon gaps inner current set 0; gaps outer current set 0
+ $mod+Ctrl+semicolon gaps inner current set 45; gaps outer current set 15
+ $mod+period gaps outer current plus 5
+ $mod+Shift+period gaps outer current minus 5
+ $mod+comma gaps inner current plus 5
+ $mod+Shift+comma gaps inner current minus 5
+
+ #### Shortcuts to control my other computer through ssh ####
+
+ # Media keys
+ $mod+XF86AudioPrev exec --no-startup-id exremote "lmc prev"
+ $mod+XF86AudioPlay exec --no-startup-id exremote "lmc toggle"
+ $mod+XF86AudioNext exec --no-startup-id exremote "lmc next"
+ $mod+XF86AudioRaiseVolume exec --no-startup-id exremote "lmc up 5"
+ $mod+XF86AudioLowerVolume exec --no-startup-id exremote "lmc down 5"
+ $mod+XF86AudioMute exec --no-startup-id exremote "lmc mute"
+
+ $mod+Ctrl+Shift+F5 exec exremote "mpc seek -10"
+ $mod+Ctrl+F5 exec exremote "lmc prev"
+ $mod+Ctrl+F6 exec exremote "lmc toggle"
+ $mod+Ctrl+F7 exec exremote "lmc next"
+ $mod+Ctrl+Shift+F7 exec exremote "mpc seek +10"
+
+ # Remote computer's clipboard
+ $mod+Ctrl+c exec clipremote copy
+ $mod+Ctrl+v exec clipremote paste
}
# bar {