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.

608 lines
22 KiB

5 years ago
5 years ago
5 years ago
5 years ago
4 years ago
5 years ago
5 years ago
4 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
5 years ago
4 years ago
4 years ago
  1. # startup [[[ #
  2. set $term kitty
  3. # set $term st
  4. # set $term urxvt
  5. # set $term_alt kitty
  6. # set $term_alt st
  7. set $term_alt urxvt
  8. {{ if eq .chezmoi.fullHostname "x1-carbon" }}
  9. exec dunst
  10. exec compton
  11. exec imwheel
  12. exec numlockx on
  13. exec xbacklight -set 10
  14. # exec wal -i "$(/home/kevin/scripts/shuffler \"/home/kevin/Pictures/Backgrounds/dim/non-editing\")"
  15. exec wal -i $(/home/kevin/scripts/shuffler "$HOME/Pictures/Backgrounds/dim/non-editing")
  16. {{ end }}
  17. # exec xrdb ~/.Xresources && grep wallpaper ~/.cache/wal/colors.sh | cut -d\' -f2 | xargs wal -i > /dev/null
  18. # exec --no-startup-id i3-msg 'workspace $ws1; exec $term'
  19. # exec --no-startup-id i3-msg 'workspace $ws2; exec $term -e fish -c "tmux-attach fortnite"'
  20. exec --no-startup-id i3-msg 'workspace $ws3; exec $browser'
  21. # exec --no-startup-id i3-msg 'workspace $ws5; exec $term -e twitchy'
  22. # ]]] startup #
  23. # applications [[[ #
  24. set $mod Mod1
  25. set $browser "firefox"
  26. # set $browser "chromium"
  27. set $scripts_path "/home/kevin/scripts"
  28. set $sch_dir "$HOME/Documents/School"
  29. # app shortcuts [[[ #
  30. set $type_delay_cmd sleep .3
  31. bindsym Control+Return exec $term
  32. bindsym Control+Shift+Return exec st -A1
  33. bindsym Control+$mod+Return exec $term_alt
  34. # bindsym Control+$mod+Return exec st
  35. # PROTIP: You can also dynamically set dmenu's colors this way:
  36. bindsym Mod4+Return exec /home/kevin/scripts/dmenu-history -nb "$fg" -nf "$bg" -sb "$bg" -sf "$fg"
  37. # bindsym Mod4+Return exec dmenu_run -nb "$fg" -nf "$bg" -sb "$bg" -sf "$fg"
  38. # bindsym Mod4+Return exec dmenu_run
  39. # There also is the (new) i3-dmenu-desktop which only displays applications
  40. # shipping a .desktop file. It is a wrapper around dmenu, so you need that
  41. # installed.
  42. # bindsym $mod+d exec --no-startup-id i3-dmenu-desktop
  43. # bindsym Mod4+b layout tabbed; exec zathura
  44. bindsym Mod4+c exec $browser
  45. # bindsym Mod4+e exec notify-send "HPS Word Count" "$(pdftotext /home/kevin/school/latex-notes/hps/essay.pdf - | wc -w)"
  46. # bindsym Mod4+e exec emacs
  47. bindsym Mod4+e exec ~/scripts/twem
  48. # bindsym Mod4+f exec firefox
  49. bindsym Mod4+f exec firefox --private-window
  50. # bindsym Mod4+$mod+f exec printf 'Kevin@fosstodon.org' | xclip -selection clipboard
  51. # bindsym Mod4+h exec sleep .2 && xdotool type '.hint'
  52. # bindsym Mod4+$mod+h exec $type_delay_cmd && xdotool type 'kevin.mok@live.ca'
  53. bindsym Mod4+h exec $type_delay_cmd && xdotool type 'kevin.mok@live.ca'
  54. # bindsym Mod4+$mod+h exec sleep .2 && xdotool type '.hint'
  55. bindsym Mod4+$mod+i exec sleep .2 && xdotool type '.info latest'
  56. # bindsym Mod4+m exec $term -e ~/scripts/vim-man
  57. bindsym Mod4+m exec $type_delay_cmd && xdotool type 'me@kevin-mok.com'
  58. # bindsym Mod4+$mod+m exec pass -c uoft/markus
  59. bindsym Mod4+n exec $term -e nvim
  60. bindsym Mod4+o exec xclip -selection clipboard ~/.password-store/social/gmail && $type_delay_cmd && xdotool key 'Control_L+v'
  61. # bindsym Mod4+o exec $type_delay_cmd && xdotool key 'Control_L+v'
  62. bindsym Mod4+$mod+o exec xset dpms force off
  63. # bindsym Mod4+p workspace $ws4; exec pgadmin3
  64. # bindsym Mod4+p exec pycharm
  65. bindsym Mod4+p exec passmenu
  66. # bindsym Mod4+p exec sleep .2 && xdotool type '.catch '
  67. # bindsym Mod4+$mod+p exec passmenu
  68. # bindsym Mod4+$mod+p exec notify-send "ping" "$(ping -c 3 -W 1 8.8.8.8)"
  69. # bindsym Mod4+q exec qdirstat
  70. bindsym Mod4+q exec printf 'emad1 ' | xclip -selection clipboard && $type_delay_cmd && xdotool key 'Control_L+v'
  71. bindsym Mod4+r exec $type_delay_cmd && xdotool type 'kmok@redhat.com'
  72. bindsym Mod4+$mod+r exec $term -e ranger
  73. # bindsym Mod4+$mod+r exec notify-send "watson restart" "$(watson restart)"
  74. bindsym Mod4+$mod+s exec $type_delay_cmd && xdotool type 'https://smol.gq/'
  75. bindsym Mod4+t exec xclip -selection clipboard ~/.password-store/social/trapbot && $type_delay_cmd && xdotool key 'Control_L+v'
  76. bindsym Mod4+u exec $type_delay_cmd && xdotool type 'kevin.mok@mail.utoronto.ca'
  77. # bindsym Mod4+$mod+u exec pass -c uoft/acorn
  78. # bindsym Mod4+w exec notify-send "watson status" "$(watson status)"
  79. # bindsym Mod4+$mod+w exec notify-send "watson stop" "$(watson status && watson stop)"
  80. bindsym Control+Mod4+w exec $term -e nvim /home/kevin/.config/watson/state.tmp
  81. # bindsym Mod4+x exec $swex
  82. bindsym Control+$mod+x exec $type_delay_cmd && xdotool type 'http://codm.ataraxy.tk/'
  83. bindsym Mod4+z exec cliqz
  84. {{ if .ext_kb }}
  85. bindsym Mod4+x exec ~/scripts/xmodmap-custom
  86. # bindsym Print --release exec "scrot -s ~/tmp/screenshot-$(date +%F_%T).png -e 'xclip -selection c -t image/png < $f'"
  87. bindsym Print --release exec "maim -su | tee ~/tmp/screenshot-$(date +%F_%T).png | xclip -selection clipboard -t image/png"
  88. bindsym Control+Print --release exec "scrot -u ~/tmp/screenshot-$(date +%F_%T).png -e 'xclip -selection c -t image/png < $f'"
  89. {{ else }}
  90. bindsym Mod4+x exec xmodmap ~/.Xmodmap-laptop && xset r rate $XSET_DELAY $XSET_RATE
  91. bindsym Control+$mod+p --release exec "scrot -s /tmp/screenshot-$(date +%F_%T).png -e 'xclip -selection c -t image/png < $f'"
  92. bindsym Control+Shift+p --release exec "scrot -u /tmp/screenshot-$(date +%F_%T).png -e 'xclip -selection c -t image/png < $f'"
  93. {{ end }}
  94. # ]]] app shortcuts #
  95. # redshift [[[ #
  96. bindsym $mod+Mod4+1 exec redshift -x && redshift -O 1100
  97. bindsym $mod+Mod4+2 exec redshift -x && redshift -O 2000
  98. bindsym $mod+Mod4+3 exec redshift -x && redshift -O 3000
  99. bindsym $mod+Mod4+4 exec redshift -x && redshift -O 4000
  100. bindsym $mod+Mod4+5 exec redshift -x && redshift -O 5000
  101. bindsym $mod+Mod4+grave exec redshift -x
  102. # ]]] redshift #
  103. # backlight [[[ #
  104. {{ if eq .chezmoi.fullHostname "x1-carbon" }}
  105. bindsym Shift+F1 exec xbacklight -set 10
  106. bindsym Shift+F2 exec xbacklight -set 20
  107. bindsym Shift+F3 exec xbacklight -set 30
  108. bindsym Shift+F4 exec xbacklight -set 40
  109. bindsym Shift+F5 exec xbacklight -set 50
  110. bindsym Shift+F6 exec xbacklight -set 60
  111. bindsym Shift+F7 exec xbacklight -set 70
  112. bindsym Shift+F8 exec xbacklight -set 80
  113. bindsym Shift+F9 exec xbacklight -set 90
  114. bindsym Shift+F0 exec xbacklight -set 100
  115. bindsym Control+$mod+plus exec xbacklight -inc 2
  116. bindsym Control+$mod+minus exec xbacklight -dec 2
  117. bindsym Control+$mod+w exec sudo systemctl start netctl-auto@wlp3s0.service
  118. bindsym Control+$mod+q exec sudo systemctl stop netctl-auto@wlp3s0.service
  119. {{ end }}
  120. # ]]] backlight #
  121. for_window [class="Peek"] floating enable
  122. for_window [title="Qalculate!"] floating enable
  123. # ]]] applications #
  124. # container display [[[ #
  125. # Font for window titles
  126. font pango:$sb_font 11
  127. bindsym $mod+s layout stacking
  128. # change container layout (stacked, tabbed, toggle split)
  129. bindsym $mod+t layout tabbed
  130. bindsym $mod+e layout toggle split
  131. # enter fullscreen mode for the focused container
  132. bindsym $mod+f fullscreen toggle
  133. # toggle tiling /floating
  134. bindsym $mod+Shift+space floating toggle
  135. # change focus between tiling / floating windows
  136. bindsym $mod+space focus mode_toggle
  137. # focus the parent container
  138. # bindsym $mod+a focus parent
  139. # focus the child container
  140. #bindsym $mod+d focus child
  141. # gaps [[[ #
  142. set $inner_gaps 20
  143. # set $inner_gaps 7
  144. # set $inner_gaps 0
  145. set $outer_gaps 0
  146. # set $border_radius 15
  147. set $border_radius 0
  148. # remove window titlebars
  149. # for_window [class="^.*"] border pixel 2
  150. for_window [class="^.*"] border pixel 3
  151. # gaps inner $inner_gaps
  152. # gaps outer $outer_gaps
  153. # gaps bottom 0
  154. gaps inner 0
  155. gaps outer 0
  156. {{ if eq .chezmoi.fullHostname "nzxt" }}
  157. border_radius $border_radius
  158. {{ end }}
  159. # other gaps [[[ #
  160. # gaps horizontal 20
  161. # gaps vertical 10
  162. # gaps top
  163. # gaps left 20
  164. # gaps right 20
  165. # gaps bottom
  166. # ]]] other gaps #
  167. bindsym Control+shift+plus gaps inner all set $inner_gaps;gaps outer all set $outer_gaps
  168. bindsym Control+shift+0 gaps inner all set 0;gaps outer all set 0
  169. # ]]] gaps #
  170. # colors from pywal [[[ #
  171. set_from_resource $fg i3wm.color7 #f0f0f0
  172. #F0F0F0
  173. # Set colors from Xresources
  174. # Change 'color7' and 'color2' to whatever colors you want i3 to use
  175. # from the generated scheme.
  176. # NOTE: The '#f0f0f0' in the lines below is the color i3 will use if
  177. # it fails to get colors from Xresources.
  178. set_from_resource $bg i3wm.color2 #f0f0f0
  179. # class border backgr. text indicator child_border
  180. client.focused $bg $bg $fg $bg $bg
  181. # client.unfocused $fg $bg $fg $bg $fg
  182. # client.urgent $bg $bg $fg $bg $bg
  183. # client.placeholder $bg $bg $fg $bg $bg
  184. # client.background $bg
  185. # ]]] colors from pywal #
  186. # ]]] container display #
  187. # moving windows [[[ #
  188. # Use Mouse+$mod to drag floating windows to their wanted position
  189. floating_modifier $mod
  190. # change focus
  191. bindsym Control+h focus left
  192. bindsym Control+j focus down
  193. bindsym Control+k focus up
  194. bindsym Control+l focus right
  195. # move workspace to other monitor
  196. bindsym $mod+minus move workspace to output left
  197. bindsym $mod+plus move workspace to output right
  198. # move focused window
  199. {{ if eq .chezmoi.fullHostname "x1-carbon" }}
  200. bindsym Control+Shift+h move left 50px
  201. bindsym Control+Shift+j move down 50px
  202. bindsym Control+Shift+k move up 50px
  203. bindsym Control+Shift+l move right 50px
  204. {{ else }}
  205. bindsym Control+Shift+h move left
  206. bindsym Control+Shift+j move down
  207. bindsym Control+Shift+k move up
  208. bindsym Control+Shift+l move right
  209. {{ end }}
  210. # split in horizontal orientation
  211. bindsym $mod+b split h
  212. bindsym Control+$mod+b split h; exec $term
  213. # split in vertical orientation
  214. bindsym $mod+v split v
  215. bindsym Mod4+$mod+v split v; exec $term
  216. # resizing windows #
  217. bindsym Control+$mod+h resize grow width 5 px or 5 ppt
  218. bindsym Control+$mod+k resize grow height 5 px or 5 ppt
  219. bindsym Control+$mod+j resize shrink height 5 px or 5 ppt
  220. bindsym Control+$mod+l resize shrink width 5 px or 5 ppt
  221. # bindsym Control+Shift+x kill
  222. bindsym shift+x kill
  223. bindsym Control+$mod+t sticky toggle
  224. # bindsym Control+$mod+a floating enable; resize set 400px 125px; move absolute position 1648 200; sticky enable
  225. bindsym Control+$mod+a floating enable; resize set 400px 150px; move absolute position 424 945; sticky enable
  226. # for_window [class="ada-mario"] floating enable
  227. # for_window [class="ada-mario"] move absolute position 640 0
  228. # ]]] moving windows #
  229. # backgrounds [[[ #
  230. set $make_st_script "/home/kevin/st/make-st.sh"
  231. # test
  232. {{ if eq .chezmoi.fullHostname "x1-carbon" }}
  233. bindsym Control+Shift+q exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/bright/editing") && $make_st_script
  234. bindsym Control+Shift+w exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/dim/non-editing") && $make_st_script
  235. bindsym Control+$mod+z exec feh --bg-fill ~/Pictures/Backgrounds/dim/black.jpg
  236. {{ else }}
  237. bindsym Control+$mod+q exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/bright/editing") && $make_st_script
  238. bindsym Control+$mod+w exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/dim/non-editing") && $make_st_script
  239. {{ end }}
  240. bindsym $mod+r exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/dim/editing") && $make_st_script
  241. bindsym Control+$mod+y exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/bright/non-editing") && $make_st_script
  242. # ]]] backgrounds #
  243. # ws names [[[ #
  244. set $ws1 "1 "
  245. {{ if eq .chezmoi.fullHostname "x1-carbon" }}
  246. set $secondary "HDMI2"
  247. set $main "eDP1"
  248. {{ else if eq .chezmoi.fullHostname "nzxt" }}
  249. set $secondary "DVI-I-1"
  250. set $main "HDMI-0"
  251. {{ end }}
  252. # workspace $ws1 output $main
  253. workspace $ws1 output $secondary
  254. bindsym $mod+F1 workspace $ws1; exec $term
  255. bindsym Control+Shift+F1 workspace $ws1; exec $term -e fish -c 'tmux-attach red-hat'
  256. set $ws2 "2 "
  257. set $wl_ip_nast_num "5"
  258. workspace $ws2 output $secondary
  259. bindsym $mod+F2 workspace $ws2; exec $term
  260. bindsym Control+Shift+F2 workspace $ws2; exec $term -e mosh kmok@192.168.0.1$wl_ip_nast_num -- tmux a -t nzxt
  261. # bindsym Control+Shift+F2 workspace $ws2; exec $term -e fish -c 'tmux-attach fortnite'
  262. set $ws3 "3 "
  263. # set $ws3 "3 "
  264. # workspace $ws3 output $main
  265. bindsym $mod+F3 workspace $ws3; exec $browser
  266. # bindsym Mod4+b workspace $ws3; layout stacked; exec $term -e fish -c "buku-fzf"
  267. # bindsym Mod4+$mod+b workspace $ws3; layout stacked; exec $term -e fish -c "buku-fzf fq"
  268. # bindsym Mod4+b layout stacked; exec $term -e fish -c "buku-fzf"
  269. # bindsym Mod4+$mod+b layout stacked; exec $term -e fish -c "buku-fzf fq"
  270. bindsym Mod4+b layout tabbed; exec $term -e fish -c "buku-fzf"
  271. bindsym Mod4+$mod+b layout tabbed; exec $term -e fish -c "buku-fzf fq"
  272. bindsym Mod4+g workspace $ws3; layout tabbed; exec gimp
  273. set $ws4 "4 "
  274. workspace $ws4 output $secondary
  275. bindsym $mod+F4 workspace $ws4; exec $term
  276. bindsym Mod4+$mod+F4 workspace $ws4; exec urxvt
  277. set $ws5 "5 "
  278. # workspace $ws5 output $secondary
  279. assign [class="Steam"] $ws5
  280. bindsym $mod+F5 workspace $ws5; exec $browser
  281. bindsym $mod+Mod4+F5 workspace $ws5; exec chromium
  282. # bindsym $mod+Mod4+F5 workspace $ws5; exec firefox --private-window
  283. bindsym $mod+Shift+F5 workspace $ws5; exec firefox --private-window
  284. # bindsym Mod4+g workspace $ws5; layout stacking; exec $term -e steam
  285. # bindsym Mod4+g workspace $ws5; layout tabbed; exec gimp
  286. # bindsym Mod4+g workspace $ws5; exec mgba-qt
  287. # bindsym Mod4+i workspace $ws5; exec idea
  288. # bindsym Mod4+m workspace $ws5; layout tabbed; exec $term -e ~/.minetest/minetest/bin/minetest
  289. bindsym Mod4+$mod+t workspace $ws5; exec thunderbird
  290. # bindsym Mod4+$mod+w workspace $ws5; exec $term -e twitchy
  291. # bindsym Mod4+w workspace $ws5; exec $term -e twitchy
  292. bindsym Mod4+5 workspace $ws5; exec godot
  293. bindsym Mod4+F5 workspace $ws5; exec cd ~/coding/ada-mario && godot -e
  294. # for_window [class="Move_mouse_with_head"] floating enable; move absolute position 0 0
  295. for_window [class="Face_detector"] floating enable
  296. for_window [class="Face_detector"] move absolute position 0 0
  297. for_window [class="ada-mario"] floating enable
  298. # for_window [class="ada-mario"] move absolute position 930 480
  299. for_window [class="ada-mario"] move absolute position 640 0
  300. set $ws6 "6 "
  301. workspace $ws6 output $secondary
  302. assign [class="Slack"] $ws6
  303. # bindsym Mod4+$mod+d workspace $ws6; exec discord
  304. bindsym Mod4+d workspace $ws6; exec riot-desktop
  305. # bindsym Mod4+d workspace $ws6; exec firefox -new-window https://riot.im/app
  306. bindsym Mod4+$mod+d workspace $ws6; exec discord
  307. # bindsym Mod4+d workspace $ws6; exec discord
  308. # bindsym Mod4+$mod+d workspace $ws6; exec riot-desktop
  309. # bindsym Mod4+d workspace $ws6; exec firefox --new-window https://discordapp.com/channels/430798446723727367/443950744996020228
  310. # bindsym Mod4+i workspace $ws6; exec firefox -new-window https://riot.im/app
  311. bindsym Mod4+k workspace $ws6; exec slack
  312. set $ws7 "7 "
  313. workspace $ws7 output $secondary
  314. # bindsym $mod+F7 workspace $ws7; exec $term
  315. bindsym $mod+F7 workspace $ws7; exec $term -e mosh --ssh='ssh -p 399' kevin@165.22.239.234 tmux a
  316. # bindsym Mod4+$mod+F7 workspace $ws7; exec $term -e fish -c 'mosh kmok@192.168.0.16 -- tmux a -t weechat'
  317. bindsym Mod4+i workspace $ws7; exec $term -e fish -c 'mosh kmok@192.168.0.1$wl_ip_nast_num -- tmux a -t weechat'
  318. bindsym Mod4+a workspace $ws7; exec android-file-transfer
  319. # bindsym Mod4+v workspace $ws7; exec VBoxManage startvm "369-a1"
  320. set $ws8 "8 "
  321. # assign [class="jetbrains-"] $ws8
  322. workspace $ws8 output $secondary
  323. # bindsym $mod+F8 workspace $ws8; exec $term
  324. # bindsym $mod+F8 workspace $ws8; exec $term -e tmux a -t journal
  325. bindsym $mod+F8 workspace $ws8; exec $term -e fish -c 'tmux-attach journal'
  326. bindsym Mod4+$mod+F8 workspace $ws8; exec libreoffice ~/Documents/red-hat/workday.ods
  327. set $ws9 "9 "
  328. workspace $ws9 output $secondary
  329. # bindsym $mod+F9 workspace $ws9; exec $term
  330. # bindsym $mod+F9 workspace $ws9; exec $term -e tmux a -t config
  331. bindsym $mod+F9 workspace $ws9; exec $term -e fish -c 'tmux-attach config'
  332. set $ws10 "10 "
  333. # set $ws10 "10 🎵"
  334. assign [class="spotify"] $ws10
  335. workspace $ws10 output $secondary
  336. set $hp 2
  337. # bindsym Mod4+v workspace $ws10; exec $term -e alsamixer -c 0
  338. bindsym Mod4+v workspace $ws10; exec $term -e alsamixer -c 1
  339. # bindsym Mod4+$mod+c workspace $ws10; exec $term -e cava
  340. # bindsym Mod4+h workspace $ws10; exec $term -e alsamixer -c $hp
  341. bindsym Mod4+s workspace $ws10; exec spotify
  342. set $ws11 "11 "
  343. # set $ws11 "11 📊"
  344. # assign [class="Summoners War Exporter"] $ws11
  345. workspace $ws11 output $secondary
  346. bindsym $mod+F11 workspace $ws11; exec $term -e htop -s PERCENT_CPU
  347. # bindsym $mod+F11 workspace $ws11; exec $term -e gotop -m
  348. # bindsym Mod4+a workspace $ws11; exec antimicro
  349. set $ws12 "12 "
  350. bindsym $mod+F12 workspace $ws12; exec $term
  351. set $ws13 "13 "
  352. bindsym Mod4+F3 workspace $ws13; exec $term
  353. set $ws14 "14"
  354. set $ws15 "15"
  355. # ]]] ws names #
  356. # ws bindings [[[ #
  357. # bindsym $mod+h workspace prev
  358. # bindsym $mod+l workspace next
  359. bindsym $mod+1 workspace $ws1
  360. bindsym $mod+2 workspace $ws2
  361. bindsym $mod+3 workspace $ws3
  362. bindsym $mod+4 workspace $ws4
  363. bindsym $mod+5 workspace $ws5
  364. bindsym $mod+6 workspace $ws6
  365. bindsym $mod+7 workspace $ws7
  366. bindsym $mod+8 workspace $ws8
  367. bindsym $mod+9 workspace $ws9
  368. bindsym $mod+0 workspace $ws10
  369. bindsym Mod4+1 workspace $ws11
  370. # bindsym Mod4+2 workspace $ws12
  371. # bindsym Mod4+3 workspace $ws13
  372. # bindsym Mod4+4 workspace $ws14
  373. # bindsym Mod4+5 workspace $ws15
  374. # move container to ws [[[ #
  375. bindsym $mod+Control+1 move container to workspace $ws1; workspace $ws1
  376. bindsym $mod+Control+2 move container to workspace $ws2; workspace $ws2
  377. bindsym $mod+Control+3 move container to workspace $ws3; workspace $ws3
  378. bindsym $mod+Control+4 move container to workspace $ws4; workspace $ws4
  379. bindsym $mod+Control+5 move container to workspace $ws5; workspace $ws5
  380. bindsym $mod+Control+6 move container to workspace $ws6; workspace $ws6
  381. bindsym $mod+Control+7 move container to workspace $ws7; workspace $ws7
  382. bindsym $mod+Control+8 move container to workspace $ws8; workspace $ws8
  383. bindsym $mod+Control+9 move container to workspace $ws9; workspace $ws9
  384. bindsym $mod+Control+0 move container to workspace $ws10; workspace $ws10
  385. bindsym $mod+Shift+1 move container to workspace $ws11; workspace $ws11
  386. bindsym $mod+Shift+2 move container to workspace $ws12; workspace $ws12
  387. bindsym $mod+Shift+3 move container to workspace $ws13; workspace $ws13
  388. bindsym $mod+Shift+4 move container to workspace $ws14; workspace $ws14
  389. bindsym $mod+Shift+5 move container to workspace $ws15; workspace $ws15
  390. # ]]] move container to ws #
  391. # ]]] ws bindings #
  392. # reload config [[[ #
  393. bindsym Control+$mod+r exec i3-msg restart
  394. bindsym $mod+Shift+c reload
  395. # bindsym $mod+Control+r reload
  396. bindsym $mod+Control+u exec xrdb ~/.Xresources && grep wallpaper ~/.cache/wal/colors.sh | cut -d\' -f2 | xargs wal -i > /dev/null
  397. # exit i3 (logs you out of your X session)
  398. bindsym Control+$mod+s exec systemctl suspend
  399. 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'"
  400. # ]]] reload config #
  401. # status bar [[[ #
  402. # bar vars [[[ #
  403. # set $sb_font Hack NF Bold
  404. # set $sb_font EmojiOne
  405. set $sb_font DejaVuSansMono Nerd Font Mono Bold
  406. set $black #000000
  407. set $white #ffffff
  408. for_window [class="Yad"] floating enable
  409. # set $inactive_ws_bg $white
  410. set $inactive_ws_bg #444c52
  411. #00ffff
  412. # set $inactive_ws_trans 96
  413. set $inactive_ws_trans 00
  414. # set $active_ws_trans 91
  415. set $active_ws_trans 4b
  416. set $focused_ws_text #ffffff
  417. # ]]] bar vars #
  418. # main bar [[[ #
  419. # set $bar_trans 64
  420. set $bar_trans 00
  421. set $main_ws_trans aa
  422. bar {
  423. i3bar_command i3bar -t
  424. {{ if eq .chezmoi.fullHostname "x1-carbon" }}
  425. font pango:$sb_font 17
  426. {{ else }}
  427. # font pango:$sb_font 17
  428. font pango:$sb_font 16
  429. {{ end }}
  430. colors {
  431. # 0 (transparent) -> 255 (opaque) in hex
  432. background $black$bar_trans
  433. # border, bg, text color
  434. # focused_workspace $inactive_ws_bg $bg $focused_ws_text
  435. focused_workspace $inactive_ws_bg $bg $fg
  436. # active = focused on other screen
  437. active_workspace $inactive_ws_bg $fg$active_ws_trans $fg
  438. inactive_workspace $inactive_ws_bg $inactive_ws_bg$inactive_ws_trans $fg
  439. }
  440. tray_output none
  441. # status_command i3blocks -c ~/.config/i3blocks/i3blocks.conf
  442. status_command 2>/tmp/i3blocks.err i3blocks -vvv -c ~/.config/i3blocks/i3blocks.conf | tee /tmp/i3blocks.out
  443. output $main
  444. wheel_up_cmd nop
  445. wheel_down_cmd nop
  446. }
  447. # ]]] main bar #
  448. # secondary bar [[[ #
  449. bar {
  450. output $secondary
  451. {{ if eq .chezmoi.fullHostname "x1-carbon" }}
  452. font pango:$sb_font 18
  453. {{ else }}
  454. font pango:$sb_font 20
  455. {{ end }}
  456. # output $main
  457. i3bar_command i3bar -t
  458. colors {
  459. background $black$bar_trans
  460. # border, bg, text color
  461. # focused_workspace $inactive_ws_bg $bg $focused_ws_text
  462. focused_workspace $inactive_ws_bg $bg $fg
  463. active_workspace $inactive_ws_bg $fg$active_ws_trans $fg
  464. inactive_workspace $inactive_ws_bg $inactive_ws_bg$inactive_ws_trans $fg
  465. }
  466. status_command i3blocks -c ~/.config/i3blocks/i3blocks-secondary.conf
  467. # status_command 2>/tmp/i3blocks-sam.err i3blocks -vvv -c ~/.config/i3blocks/sam-i3blocks.conf | tee /tmp/i3blocks-sam.out
  468. tray_output none
  469. wheel_up_cmd nop
  470. wheel_down_cmd nop
  471. }
  472. # ]]] secondary bar #
  473. # display bar [[[ #
  474. # bar {
  475. # i3bar_command i3bar -t
  476. # font pango:$sb_font 23
  477. # tray_output none
  478. # status_command i3blocks -c ~/.config/i3blocks/i3blocks-display.conf
  479. # output $secondary
  480. # wheel_up_cmd nop
  481. # wheel_down_cmd nop
  482. # }
  483. # ]]] display bar #
  484. # ]]] status bar #
  485. # media keys [[[ #
  486. # sink
  487. bindsym XF86AudioRaiseVolume exec amixer -q -D pulse sset Master 5%+ && pkill -RTMIN+1 i3blocks
  488. bindsym Control+d exec ~/linux-config/scripts/change-sink dac
  489. # bindsym Control+shift+d exec ~/linux-config/scripts/change-sink dac2
  490. bindsym Control+o exec ~/linux-config/scripts/change-sink line-out
  491. # media
  492. # fn key [[[ #
  493. bindsym XF86AudioLowerVolume exec amixer -q -D pulse sset Master 5%- && pkill -RTMIN+1 i3blocks
  494. bindsym XF86AudioMute exec amixer -q -D pulse sset Master toggle && pkill -RTMIN+1 i3blocks
  495. bindsym XF86AudioPlay exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause"
  496. # bindsym XF86AudioStop exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Stop"
  497. bindsym XF86AudioPrev exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Previous"
  498. bindsym XF86AudioNext exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Next"
  499. # ]]] fn key #
  500. # ]]] media keys #
  501. # vim: fdm=marker ft=i3.go-template