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.

675 lines
25 KiB

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