diff --git a/dot_Xresources.tmpl b/dot_Xresources.tmpl index 5ea813f..f6f6c8e 100755 --- a/dot_Xresources.tmpl +++ b/dot_Xresources.tmpl @@ -1,5 +1,3 @@ -# vim: fdm=marker ft=xdefaults.go-template - /* font [[[ */ {{ if eq .chezmoi.fullHostname "x1-carbon" }} @@ -54,3 +52,5 @@ Xft.antialias: 1 Xft.rgba: rgb /* ]]] HiDPI */ + +# vim: fdm=marker ft=xdefaults.go-template diff --git a/dot_config/i3/config.tmpl b/dot_config/i3/config.tmpl index cddbfe8..71f638d 100755 --- a/dot_config/i3/config.tmpl +++ b/dot_config/i3/config.tmpl @@ -1,40 +1,28 @@ -# vim: fdm=marker ft=i3.go-template - # startup [[[ # -set $browser "firefox" -# set $browser "chromium" -set $term "urxvt" -set $scripts_path "/home/kevin/scripts" -exec redshift -O 2000 -# exec redshift -O 3000 -# random bg -exec compton -exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/dim/non-editing") -exec imwheel -exec xmodmap ~/.Xmodmap -exec xset r rate $XSET_DELAY $XSET_RATE {{ if eq .chezmoi.fullHostname "x1-carbon" }} exec xbacklight -set 10 {{ end }} -exec xrdb ~/.Xresources -exec --no-startup-id dunst -exec --no-startup-id start-pulseaudio-x11 exec --no-startup-id i3-msg 'workspace $ws2; exec $term' exec --no-startup-id i3-msg 'workspace $ws3; exec $browser' -# exec --no-startup-id i3-msg 'workspace $ws11; exec $swex' -exec_always --no-startup-id numlockx on # ]]] startup # # applications [[[ # set $mod Mod1 +set $browser "firefox" +# set $browser "chromium" +# set $term "urxvt" +set $term "st" +set $scripts_path "/home/kevin/scripts" set $sch_dir "$HOME/Documents/School" # app shortcuts [[[ # bindsym control+Return exec $term +bindsym control+$mod+Return exec urxvt +# bindsym control+$mod+Return exec st # PROTIP: You can also dynamically set dmenu's colors this way: bindsym Mod4+Return exec dmenu_run -nb "$fg" -nf "$bg" -sb "$bg" -sf "$fg" # bindsym Mod4+Return exec dmenu_run @@ -59,7 +47,6 @@ bindsym Mod4+p exec passmenu bindsym Mod4+q exec qdirstat bindsym Mod4+r exec urxvt -e ranger bindsym Mod4+$mod+r exec notify-send "watson restart" "$(watson restart)" -# bindsym Mod4+t exec st bindsym Mod4+$mod+t exec xclip -selection clipboard ~/.password-store/social/trapbot bindsym Mod4+u exec echo 'kevin.mok@mail.utoronto.ca' | xclip -selection clipboard bindsym Mod4+$mod+u exec pass -c uoft/acorn @@ -174,6 +161,7 @@ bindsym control+shift+0 gaps inner all set 0;gaps outer all set 0 # colors from pywal [[[ # set_from_resource $fg i3wm.color7 #f0f0f0 +#F0F0F0 # Set colors from Xresources # Change 'color7' and 'color2' to whatever colors you want i3 to use # from the generated scheme. @@ -234,6 +222,8 @@ bindsym shift+x kill # backgrounds [[[ # +set $make_st_script "/home/kevin/st/make-st.sh" + {{ if eq .chezmoi.fullHostname "x1-carbon" }} bindsym control+$mod+q exec wal -i "$HOME/Pictures/Backgrounds/bright/editing"; exec ~/.cache/wal/colors.sh bindsym control+$mod+w exec /home/kevin/linux-config/scripts/bg-chooser; exec ~/.cache/wal/colors.sh @@ -241,11 +231,11 @@ bindsym $mod+r exec wal -i "$HOME/Pictures/Backgrounds/dim/editing"; exec ~/.cac # bindsym $mod+r exec wal -i "$HOME/Pictures/Backgrounds/"; exec ~/.cache/wal/colors.sh bindsym control+$mod+z exec feh --bg-fill ~/Pictures/Backgrounds/dim/black.jpg {{ else }} -bindsym $mod+q exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/bright/editing") -bindsym $mod+w exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/dim/non-editing") +bindsym $mod+q exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/bright/editing") && $make_st_script +bindsym $mod+w exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/dim/non-editing") && $make_st_script # bindsym $mod+w exec ~/linux-config/scripts/bg-chooser -bindsym $mod+r exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/dim/editing") -bindsym $mod+y exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/bright/non-editing") +bindsym $mod+r exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/dim/editing") && $make_st_script +bindsym $mod+y exec wal -i $($scripts_path/shuffler "$HOME/Pictures/Backgrounds/bright/non-editing") && $make_st_script {{ end }} # ]]] backgrounds # @@ -278,7 +268,6 @@ workspace $ws4 output $secondary bindsym $mod+F4 workspace $ws4; exec $term set $ws5 "5 " -# set $ws5 "5 🎥" workspace $ws5 output $secondary assign [class="Steam"] $ws5 bindsym $mod+F5 workspace $ws5; exec $browser @@ -296,19 +285,16 @@ bindsym Mod4+d workspace $ws6; exec discord bindsym Mod4+k workspace $ws6; exec slack set $ws7 "7 " -# set $ws7 "7 📤" workspace $ws7 output $secondary bindsym $mod+F7 workspace $ws7; exec $term # bindsym Mod4+v workspace $ws7; exec VBoxManage startvm "369-a1" set $ws8 "8 " -# set $ws8 "8 📊" # assign [class="jetbrains-"] $ws8 workspace $ws8 output $secondary bindsym $mod+F8 workspace $ws8; exec $term set $ws9 "9 " -# set $ws9 "9 🔧" workspace $ws9 output $secondary bindsym $mod+F9 workspace $ws9; exec $term @@ -409,6 +395,7 @@ for_window [class="Yad"] floating enable # set $inactive_ws_bg $white set $inactive_ws_bg #444c52 +#00ffff # set $inactive_ws_trans 96 set $inactive_ws_trans 00 @@ -512,3 +499,5 @@ bindsym XF86AudioPrev exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer bindsym XF86AudioNext exec "dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Next" # ]]] media keys # + +# vim: fdm=marker ft=i3.go-template diff --git a/dot_config/ranger/rc.conf b/dot_config/ranger/rc.conf.tmpl similarity index 98% rename from dot_config/ranger/rc.conf rename to dot_config/ranger/rc.conf.tmpl index d95673d..25826ed 100755 --- a/dot_config/ranger/rc.conf +++ b/dot_config/ranger/rc.conf.tmpl @@ -1,4 +1,6 @@ -# default {{{ # +# vim: fdm=marker ft=conf.go-template + +# default [[[ # # =================================================================== # This file contains the default startup commands for ranger. # To change them, it is recommended to create the file @@ -632,9 +634,9 @@ tmap eval -q fm.ui.taskview.task_remove() tmap redraw_window tmap taskview_close copytmap q Q w -# }}} # +# ]]] # -# image preview {{{ # +# image preview [[[ # # Use one of the supported image preview protocols set preview_images true @@ -663,18 +665,19 @@ set preview_images true # The same as urxvt but utilizing not only the preview pane but the # whole terminal window. set preview_images_method w3m +# set preview_images_method ueberzug # set preview_images_method urxvt # set preview_images_method urxvt-full -# }}} image preview # +# ]]] image preview # -# custom {{{ # +# custom [[[ # # editing ranger config map R chain shell nvim -p ~/.config/ranger/rc.conf %rangerdir/config/rc.conf; source ~/.config/ranger/rc.conf map rr source ~/.config/ranger/rc.conf -# backgrounds {{{ # +# backgrounds [[[ # map w shell /usr/bin/wal -i %f map bde shell mv %f /home/kevin/Pictures/Backgrounds/dim/editing @@ -684,7 +687,7 @@ map bbn shell mv %f /home/kevin/Pictures/Backgrounds/bright/non-editing map be shell mv %f editing map bn shell mv %f non-editing -# }}} backgrounds # +# ]]] backgrounds # # bulk rename map cw eval fm.execute_console("bulkrename") if fm.thisdir.marked_items else fm.open_console("rename ") @@ -695,7 +698,7 @@ map zr shell unzip %f && rm %f map e. open_with evince f map v. shell $EDITOR %f -source ~/.config/ranger/key_mappings.conf +source {{ .chezmoi.homedir }}/.config/ranger/key_mappings.conf map dg shell dragon-drag-and-drop -a -x %p # map shell dragon-drag-and-drop -a -x %p @@ -703,4 +706,4 @@ map dg shell dragon-drag-and-drop -a -x %p # https://github.com/alexanderjeurissen/ranger_devicons default_linemode devicons -# }}} custom # +# ]]] custom # diff --git a/dot_vimrc.tmpl b/dot_vimrc.tmpl index 0c27494..91b9453 100755 --- a/dot_vimrc.tmpl +++ b/dot_vimrc.tmpl @@ -22,13 +22,15 @@ set relativenumber set shiftwidth=4 set tabstop=4 " set t_Co=256 +" set termguicolors " set timeoutlen=500 set timeoutlen=350 " set tw=80 set tw=75 set undodir=~/.vim/undo set undofile -set updatetime=1000 +" set updatetime=1000 +set updatetime=500 autocmd VimResized * wincmd = filetype plugin on @@ -55,6 +57,7 @@ autocmd FileType *css,htmldjango,html,javascript,json,markdown,tex,text,yaml set " autocmd Filetype markdown set textwidth=0 " autocmd Filetype html set foldmarker=0 autocmd BufNewFile,BufRead *.gd set expandtab! +autocmd Filetype go set expandtab! sw=4 autocmd Filetype markdown map :LivedownToggle autocmd Filetype markdown nnoremap >>A autocmd Filetype markdown inoremap < :silent !cd %:p:h; sudo rm config.h; sudo bear make install +autocmd BufRead config.def.h map :silent !cd %:p:h:!sudo rm config.h; sudo bear make install +autocmd BufRead config.def.h set updatetime=3000 autocmd BufRead commit-msg.txt set filetype=gitcommit tw=72 " autocmd BufWritePost key_* !sync-shortcuts autocmd BufNewFile,BufRead key_* map :w:silent !sync-shortcuts @@ -231,7 +238,7 @@ Plug 'djoshea/vim-autoread' " Plug 'trapd00r/vim-syntax-vidir-ls' Plug 'calviken/vim-gdscript3' " display hex colors in Vim -" Plug 'RRethy/vim-hexokinase' +Plug 'RRethy/vim-hexokinase' " ]]] vim-plug " " Mappings [[[ " @@ -240,6 +247,7 @@ call plug#end() " colorscheme gotham256 colorscheme wal +nnoremap v nnoremap > >> nnoremap < << inoremap << <x 0f[lrx " nnoremap x 0f[lrx autocmd Filetype go-template inoremap e {{"{{ else }}"}} +autocmd Filetype go-template inoremap hd {{"{{ .chezmoi.homedir }}"}} +autocmd Filetype go-template nnoremap fp :%s/{{"{{{"}}/[[[/g:%s/}}}/]]]/g " ]]] Local Mappings " diff --git a/dot_xinitrc b/dot_xinitrc index 0d8c6b4..732ddf2 100755 --- a/dot_xinitrc +++ b/dot_xinitrc @@ -1,5 +1,26 @@ -numlockx xrandr --setprovideroutputsource modesetting NVIDIA-0 [[ -f ~/.Xresources ]] && xrdb -merge ~/.Xresources # xrandr --auto +xmodmap ~/.Xmodmap +redshift -O 2000 +xset r rate $XSET_DELAY $XSET_RATE +# exec /home/kevin/Downloads/dwm/reload-dwm.sh + +dunst & +compton -b +imwheel & +numlockx on & +start-pulseaudio-x11 & + +wal -i $(/home/kevin/scripts/shuffler "$HOME/Pictures/Backgrounds/dim/non-editing") && /home/kevin/st/make-st.sh & exec i3 + +# # Statusbar loop +# while true; do + # xsetroot -name "$( date +"%R.%a-%m-%d" )" + # sleep 1m # Update time every minute +# done & + +# # wal -i $(/home/kevin/scripts/shuffler "$HOME/Pictures/Backgrounds/dim/non-editing") & +# wal -i "$HOME/Pictures/Backgrounds/dim/editing/captain-marvel.jpg" & +# exec dwm diff --git a/key_aliases.tmpl b/key_aliases.tmpl index 3b5d0da..b8e08b3 100755 --- a/key_aliases.tmpl +++ b/key_aliases.tmpl @@ -58,7 +58,7 @@ udub "udisksctl unmount -b /dev/sdc2" # ]]] mounting # tc "touch" -vd "vidir --verbose" +vdr "vidir --verbose" # directory-related [[[ # @@ -116,6 +116,7 @@ vlm "alsamixer -c 1" # ]]] apt # +{{ if eq .chezmoi.osRelease.id "arch" }} # pacman [[[ # # pc "sudo pacman -S" @@ -148,6 +149,7 @@ yaug "yay -Syu --answerclean=None --answerdiff=None --answeredit=None" xya "yay -Qqne > ~/{{ .chezmoi.os }}-config/txt/{{ .chezmoi.fullHostname }}-pkgs.txt && yay -Qqme > ~/{{ .chezmoi.os }}-config/txt/{{ .chezmoi.fullHostname }}-aur.txt " # ]]] yay # +{{ end }} py "python" pipi "sudo pip install" @@ -160,6 +162,9 @@ rdh "sudo killall dhcpcd && sudo dhcpcd" id "identify" # rz "source ~/{{ .chezmoi.os }}-config/aliases/zsh_aliases" + +mst "sudo rm config.h && sudo bear make install" + # system ]]] # applications [[[ # @@ -188,6 +193,7 @@ pdft "pdftotext" pipes "pipes.sh -t 3" py "python" r "ranger" +rg "printf '\033c' && rg" rx "redshift -x" sn "sudo nvim" vmd "vimdiff" @@ -351,6 +357,7 @@ zm "chezmoi" za "chezmoi add" zar "chezmoi add -r" zd "chezmoi data" +zdf "chezmoi diff" zp "chezmoi -v apply" # ]]] chezmoi # diff --git a/key_dirs.tmpl b/key_dirs.tmpl index b507087..5cbf313 100755 --- a/key_dirs.tmpl +++ b/key_dirs.tmpl @@ -4,9 +4,10 @@ bg ~/Pictures/Backgrounds cf ~/.config +cff ~/.config/fish d ~/Downloads +dw ~/dwm D ~/Documents -fo ~/.config/fish k ~/ lc ~/linux-config lf /mnt/linux-files @@ -15,6 +16,7 @@ me /run/media/{{ .chezmoi.group }} o / p ~/.password-store P ~/Pictures +std ~/st sw ~/.local/share/nvim/swap/ tm /tmp @@ -26,14 +28,14 @@ b1 ~/coding/mf-site/themes/base16 2d ~/coding/godot-demos/2d-plat ad ~/coding/ada-mario-prep cn ~/coding -ib ~/linux-config/i3blocks/.config/i3blocks/scripts +ib ~/linux-config/dot_config/i3blocks/scripts j ~/Documents/journal lh ~/Documents/listening-history mm ~/coding/move-mouse-with-head ms ~/coding/mf-site mh ~/coding/mf-site/layouts # mg ~/coding/best-mf-site-personal -ra ~/.config/ranger +ra ~/linux-config/dot_config/ranger sr ~/linux-config/scripts snp ~/.vim/plugged/vim-snippets/UltiSnips sv ~/coding/spotify-lib-vis/src diff --git a/key_files.tmpl b/key_files.tmpl index b8e1da6..43c884e 100755 --- a/key_files.tmpl +++ b/key_files.tmpl @@ -4,17 +4,19 @@ 3 ~/linux-config/dot_config/i3/config.tmpl a ~/linux-config/key_aliases.tmpl -dr ~/linux-config/key_dirs.tmpl +d ~/linux-config/key_dirs.tmpl +dw ~/dwm/config.def.h f ~/linux-config/key_files.tmpl hs ~/.local/share/fish/fish_history -i ~/.config/i3blocks/i3blocks.conf p ~/linux-config/txt/pacman-pkgs/pacman-pkgs.txt -r ~/linux-config/dot_config/ranger/rc.conf +r ~/linux-config/dot_config/ranger/rc.conf.tmpl sr ~/linux-config/configs/ranger/shortcuts.conf ss ~/.shortcuts -u ~/.Xresources +st ~/st/config.def.h +u ~/linux-config/dot_Xresources.tmpl v ~/linux-config/dot_vimrc.tmpl x ~/linux-config/dot_config/fish/config.fish.tmpl +xi ~/linux-config/dot_xinitrc y ~/.zshrc z ~/linux-config/aliases/zsh_aliases diff --git a/scripts/executable_sync-shortcuts b/scripts/executable_sync-shortcuts index dad8d4e..8a5b8ca 100755 --- a/scripts/executable_sync-shortcuts +++ b/scripts/executable_sync-shortcuts @@ -26,7 +26,7 @@ ranger_mappings="$HOME/.config/ranger/key_mappings.conf" # ensure sourcing new file in orig. config file ensure "source $aliases" "$bashrc" ensure "source $aliases" "$zshrc" -ensure "source $fish_abbr" "$fish_config" +# ensure "source $fish_abbr" "$fish_config" ensure "source $ranger_mappings" "$ranger_config" # key files diff --git a/txt/todo.md b/txt/todo.md index 227f40c..27cd7dd 100755 --- a/txt/todo.md +++ b/txt/todo.md @@ -1,6 +1,7 @@ # chezmoi - scripts - copy sync-shortcut + - YCM # Other - nnn?