Dotfiles for my tiling window manager + terminal workflow.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

282 lines
9.4 KiB

  1. # applications {{{ #
  2. # startup {{{ #
  3. set $def_term "rxvt-unicode"
  4. exec redshift -O 4000
  5. # random bg
  6. exec ~/.local/bin/wal -i "$HOME/Pictures/Backgrounds/vibrant"
  7. # exec_always ~/.local/bin/wal -i "$HOME/Pictures/Backgrounds/retro-mountains-pink.jpg"
  8. exec imwheel
  9. # exec --no-startup-id i3-msg 'workspace 1 ; exec $def_term'
  10. exec --no-startup-id i3-msg 'workspace 2 ; exec $def_term'
  11. exec --no-startup-id i3-msg 'workspace 3 ; exec google-chrome'
  12. # }}} startup #
  13. set $sch_dir "$HOME/Documents/School"
  14. # app shortcuts {{{ #
  15. bindsym Mod4+a exec studio
  16. # bindsym $mod+control+Return exec i3-sensible-terminal
  17. bindsym $mod+control+Return exec $def_term
  18. bindsym Mod4+c exec google-chrome
  19. bindsym Mod4+e exec nemo
  20. bindsym Mod4+o exec okular
  21. bindsym Mod4+m exec okular $sch_dir/calc-textbook.pdf
  22. bindsym Mod4+p exec pycharm
  23. bindsym Mod4+r exec urxvt -e ranger
  24. bindsym Print exec ksnapshot
  25. # }}} app shortcuts #
  26. # redshift {{{ #
  27. bindsym $mod+Mod4+1 exec redshift -O 1500
  28. bindsym $mod+Mod4+2 exec redshift -O 2000
  29. bindsym $mod+Mod4+3 exec redshift -O 2500
  30. bindsym $mod+Mod4+4 exec redshift -O 3000
  31. bindsym $mod+Mod4+5 exec redshift -O 4000
  32. bindsym $mod+Mod4+0 exec redshift -x
  33. # }}} redshift #
  34. # menu {{{ #
  35. # start dmenu (a program launcher)
  36. bindsym Mod4+Return exec dmenu_run
  37. # There also is the (new) i3-dmenu-desktop which only displays applications
  38. # shipping a .desktop file. It is a wrapper around dmenu, so you need that
  39. # installed.
  40. # bindsym $mod+d exec --no-startup-id i3-dmenu-desktop
  41. # }}} menu #
  42. # Use Mouse+$mod to drag floating windows to their wanted position
  43. floating_modifier $mod
  44. # }}} applications #
  45. # changing/focusing/moving windows {{{ #
  46. # change focus
  47. bindsym control+h focus left
  48. bindsym control+j focus down
  49. bindsym control+k focus up
  50. bindsym control+l focus right
  51. # move workspace to other monitor
  52. bindsym $mod+minus move workspace to output left
  53. bindsym $mod+plus move workspace to output right
  54. # alternatively, you can use the cursor keys:
  55. bindsym $mod+Left focus left
  56. bindsym $mod+Down focus down
  57. bindsym $mod+Up focus up
  58. bindsym $mod+Right focus right
  59. # move focused window
  60. bindsym control+Shift+h move left
  61. bindsym control+Shift+j move down
  62. bindsym control+Shift+k move up
  63. bindsym control+Shift+l move right
  64. # alternatively, you can use the cursor keys:
  65. bindsym $mod+Shift+Left move left
  66. bindsym $mod+Shift+Down move down
  67. bindsym $mod+Shift+Up move up
  68. bindsym $mod+Shift+Right move right
  69. # split in horizontal orientation
  70. bindsym $mod+b split h
  71. # split in vertical orientation
  72. bindsym $mod+v split v
  73. bindsym control+Shift+x kill
  74. # }}} changing/focusing/moving windows #
  75. # container display {{{ #
  76. # backgrounds
  77. bindsym $mod+q exec ~/.local/bin/wal -i "$HOME/Pictures/Backgrounds/vibrant"
  78. bindsym $mod+w exec ~/.local/bin/wal -i "$HOME/Pictures/Backgrounds/dim"
  79. bindsym $mod+r exec ~/.local/bin/wal -i "$HOME/Pictures/Backgrounds/"
  80. bindsym $mod+z exec ~/.local/bin/wal -i "$HOME/Pictures/Backgrounds/sunset-2.jpg"
  81. # enter fullscreen mode for the focused container
  82. bindsym $mod+f fullscreen toggle
  83. # change container layout (stacked, tabbed, toggle split)
  84. bindsym $mod+s layout stacking
  85. bindsym $mod+t layout tabbed
  86. bindsym $mod+e layout toggle split
  87. # toggle tiling /floating
  88. bindsym $mod+Shift+space floating toggle
  89. # change focus between tiling / floating windows
  90. bindsym $mod+space focus mode_toggle
  91. # focus the parent container
  92. bindsym $mod+a focus parent
  93. # focus the child container
  94. #bindsym $mod+d focus child
  95. # }}} container display #
  96. # workspace {{{ #
  97. # ws names {{{ #
  98. set $samsung "DVI-I-1"
  99. set $benq "HDMI-0"
  100. set $ws1 "1 "
  101. workspace $ws1 output $benq
  102. bindsym $mod+F1 workspace $ws1; exec $def_term
  103. set $ws2 "2 "
  104. workspace $ws2 output $samsung
  105. bindsym $mod+F2 workspace $ws2; exec $def_term
  106. set $ws3 "3 "
  107. workspace $ws3 output $benq
  108. bindsym $mod+F3 workspace $ws3; exec google-chrome
  109. set $ws4 "4 "
  110. workspace $ws4 output $samsung
  111. set $ws5 "5 "
  112. workspace $ws5 output $benq
  113. bindsym $mod+F5 workspace $ws5; exec google-chrome
  114. set $ws6 "6 "
  115. workspace $ws6 output $samsung
  116. bindsym Mod4+d workspace $ws6; exec discord
  117. bindsym Mod4+l workspace $ws6; exec slack
  118. assign [class="Slack"] $ws6
  119. set $ws7 "7 "
  120. workspace $ws7 output $samsung
  121. bindsym $mod+F7 workspace $ws7; exec $def_term
  122. set $ws8 "8 "
  123. assign [class="jetbrains-"] $ws8
  124. set $ws9 "9 "
  125. workspace $ws9 output $samsung
  126. bindsym $mod+F9 workspace $ws9; exec $def_term
  127. set $ws10 "10 "
  128. assign [class="VirtualBox"] $ws10
  129. bindsym Mod4+s workspace $ws10; exec spotify
  130. set $ws11 "11 "
  131. workspace $ws11 output $benq
  132. bindsym $mod+F11 workspace $ws11; exec $def_term
  133. # }}} ws names #
  134. # ws bindings {{{ #
  135. # switch to workspace
  136. bindsym $mod+h workspace prev
  137. bindsym $mod+l workspace next
  138. bindsym $mod+1 workspace $ws1
  139. bindsym $mod+2 workspace $ws2
  140. bindsym $mod+3 workspace $ws3
  141. bindsym $mod+4 workspace $ws4
  142. bindsym $mod+5 workspace $ws5
  143. bindsym $mod+6 workspace $ws6
  144. bindsym $mod+7 workspace $ws7
  145. bindsym $mod+8 workspace $ws8
  146. bindsym $mod+9 workspace $ws9
  147. bindsym $mod+0 workspace $ws10
  148. bindsym $mod+Shift+1 workspace $ws11
  149. # }}} ws bindings #
  150. # move container to ws {{{ #
  151. # move focused container to workspace
  152. # bindsym $mod+control+1 move container to workspace $ws1
  153. # bindsym $mod+control+2 move container to workspace $ws2
  154. # bindsym $mod+control+3 move container to workspace $ws3
  155. # bindsym $mod+control+4 move container to workspace $ws4
  156. bindsym $mod+control+1 move container to workspace $ws1; workspace $ws1
  157. bindsym $mod+control+2 move container to workspace $ws2; workspace $ws2
  158. bindsym $mod+control+3 move container to workspace $ws3; workspace $ws3
  159. bindsym $mod+control+4 move container to workspace $ws4; workspace $ws4
  160. bindsym $mod+control+5 move container to workspace $ws5; workspace $ws5
  161. bindsym $mod+control+6 move container to workspace $ws6; workspace $ws6
  162. bindsym $mod+control+7 move container to workspace $ws7; workspace $ws7
  163. bindsym $mod+control+8 move container to workspace $ws8; workspace $ws8
  164. bindsym $mod+control+9 move container to workspace $ws9; workspace $ws9
  165. bindsym $mod+control+0 move container to workspace $ws10; workspace $ws10
  166. bindsym $mod+control+Shift+1 move container to workspace $ws11
  167. # }}} move container to ws #
  168. # }}} workspace #
  169. # reload config/computer {{{ #
  170. bindsym $mod+Shift+s exec systemctl suspend
  171. # restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
  172. bindsym $mod+control+r restart
  173. # reload the configuration file
  174. bindsym $mod+Shift+c reload
  175. # exit i3 (logs you out of your X session)
  176. bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'"
  177. # }}} reload config #
  178. # resizing windows {{{ #
  179. bindsym $mod+control+h resize grow width 3 px or 3 ppt
  180. bindsym $mod+control+k resize grow height 3 px or 3 ppt
  181. bindsym $mod+control+j resize shrink height 3 px or 3 ppt
  182. bindsym $mod+control+l resize shrink width 3 px or 3 ppt
  183. # }}} resizing windows #
  184. # gaps {{{ #
  185. # remove window titlebars
  186. for_window [class="^.*"] border pixel 0
  187. # default gaps
  188. gaps inner 25
  189. gaps outer 5
  190. # increase/decrease gaps
  191. bindsym control+shift+plus gaps inner all plus 2;gaps outer all plus 2
  192. # bindsym control+shift+plus gaps inner all plus 2
  193. bindsym control+shift+0 gaps inner all minus 2;gaps outer all minus 2
  194. # }}} gaps #
  195. # status bar {{{ #
  196. # Start i3bar to display a workspace bar (plus the system information i3status
  197. # finds out, if available)
  198. set $sb_font Hack Bold
  199. bar {
  200. font pango:$sb_font 17
  201. tray_output none
  202. status_command i3blocks -c ~/.config/i3blocks/i3blocks.conf
  203. output HDMI-0
  204. }
  205. bar {
  206. output $samsung
  207. status_command i3blocks -c ~/.config/sam-i3blocks/sam-i3blocks.conf
  208. tray_output none
  209. font pango:$sb_font 22
  210. # font pango:monospace 22, FontAwesome 22
  211. }
  212. # }}} status bar #
  213. # mod key/font {{{ #
  214. set $mod Mod1
  215. # Font for window titles. Will also be used by the bar unless a different font
  216. # is used in the bar {} block below.
  217. font pango:Hack 11
  218. # This font is widely installed, provides lots of unicode glyphs, right-to-left
  219. # text rendering and scalability on retina/hidpi displays (thanks to pango).
  220. #font pango:DejaVu Sans Mono 8
  221. # Before i3 v4.8, we used to recommend this one as the default:
  222. # font -misc-fixed-medium-r-normal--13-120-75-75-C-70-iso10646-1
  223. # The font above is very space-efficient, that is, it looks good, sharp and
  224. # clear in small sizes. However, its unicode glyph coverage is limited, the old
  225. # X core fonts rendering does not support right-to-left and this being a bitmap
  226. # font, it doesn’t scale on retina/hidpi displays.
  227. # }}} mod key/font #
  228. # media keys {{{ #
  229. bindsym XF86AudioRaiseVolume exec --no-startup-id amixer -c 2 sset Master 3+
  230. bindsym XF86AudioLowerVolume exec --no-startup-id amixer -c 2 sset Master 3-
  231. bindsym XF86AudioMute exec --no-startup-id amixer -D pulse set Master 2+ toggle
  232. # Media player controls
  233. bindsym XF86AudioPlay exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause"
  234. bindsym XF86AudioStop exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Stop"
  235. bindsym XF86AudioPrev exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Previous"
  236. bindsym XF86AudioNext exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Next"
  237. # }}} media keys #