diff --git a/.bash_aliases b/.bash_aliases index f4e0bb8..a27d5fa 100644 --- a/.bash_aliases +++ b/.bash_aliases @@ -54,7 +54,7 @@ alias path="echo -e ${PATH//:/\\n}" # Pretty print path variables alias feh="feh -B black --scale-down --auto-zoom" alias fm='pcmanfm' alias v="nvim" -alias w="nvim +WikiIndex" +alias zk="nvim +WikiIndex" alias g='git' alias lm='xbacklight -set' alias py='python' diff --git a/.bashrc b/.bashrc index da9be12..683c813 100644 --- a/.bashrc +++ b/.bashrc @@ -112,3 +112,6 @@ export JUPYTERLAB_DIR=$HOME/.local/share/jupyter/lab # Conda {{{ [ -f /opt/miniconda3/etc/profile.d/conda.sh ] && source /opt/miniconda3/etc/profile.d/conda.sh # }}} + +# Zettelkasten {{{ +export ZK_PATH="$HOME/.zk" diff --git a/.bin/save-wiki b/.bin/save-wiki deleted file mode 100755 index fe5ac69..0000000 --- a/.bin/save-wiki +++ /dev/null @@ -1,6 +0,0 @@ -#!/usr/bin/env bash - -cd "$HOME/.wiki" || echo "No .vimwiki directory found" -git a "$HOME/.wiki" -git cm 'Update' -git push diff --git a/.bin/save-zk b/.bin/save-zk new file mode 100755 index 0000000..4351709 --- /dev/null +++ b/.bin/save-zk @@ -0,0 +1,4 @@ +#!/usr/bin/env bash + +cd "$ZK_PATH" || echo "No zettelkasten directory found" +git a . && git commit -m "Update" && git push diff --git a/.bin/tmux-workspace b/.bin/tmux-workspace index fa5992f..6d4e1d1 100755 --- a/.bin/tmux-workspace +++ b/.bin/tmux-workspace @@ -5,13 +5,14 @@ session="main" tmux attach-session -t $session || tmux new-session -s $session \; \ rename-window todo \; \ send-keys -t 0 "task" C-m \; \ - new-window -n wiki \; \ - send-keys -t 0 "vim $HOME/.wiki/index.md" C-m \; \ + new-window -n zk \; \ + send-keys -t 0 "nvim $ZK_PATH/index.md" C-m \; \ new-window -n music \; \ send-keys -t 0 "ncspot" C-m \; \ new-window -n term \; \ new-window -n make \; \ split-window -h \; \ - send-keys -t 0 'cd "$HOME/.wiki" && ./entr' C-m \; \ - send-keys -t 1 'cd "$HOME/.wiki" && live-server . --watch *.html' C-m \; \ + split-window -h \; \ + send-keys -t 0 'cd "$ZK_PATH" && ./entr' C-m \; \ + send-keys -t 1 'cd "$ZK_PATH" && live-server . --watch=*.html' C-m \; \ select-window -t 2 \; diff --git a/.gitignore b/.gitignore index 066564d..8bc431b 100644 --- a/.gitignore +++ b/.gitignore @@ -83,8 +83,8 @@ dkms.conf # Dotenv .env -.wiki/* -!.wiki/Makefile -!.wiki/pandoc.css -!.wiki/scripts/ -!.wiki/filters/ +.zk/* +!.zk/Makefile +!.zk/pandoc.css +!.zk/scripts/ +!.zk/filters/ diff --git a/.vim/coc-settings.json b/.vim/coc-settings.json index 1c2ab94..929d131 100644 --- a/.vim/coc-settings.json +++ b/.vim/coc-settings.json @@ -149,7 +149,7 @@ "svelte.enable-ts-plugin": true, // Add BibTex file for coc-bibtex autocompletion - "list.source.bibtex.files": ["~/.wiki/references.bib", "./*.bib"], + "list.source.bibtex.files": ["~/.zk/references.bib", "./*.bib"], "bibtex.silent": true, // Adjust floating menus diff --git a/.vimrc b/.vimrc index 3856c2d..1c3866b 100644 --- a/.vimrc +++ b/.vimrc @@ -352,17 +352,17 @@ let g:pandoc#syntax#conceal#cchar_overrides = { "atx": " ", "li": "ยท" } " `euclio/vim-markdown-composer` {{{ -let g:markdown_composer_custom_css = ['file:///home/h/.wiki/pandoc.css'] -let g:markdown_composer_external_renderer='pandoc -f markdown+latex_macros-yaml_metadata_block -t html5 --mathjax --bibliograph /home/h/.wiki/references.bib --citeproc --lua-filter=/home/h/.wiki/lua-filters/diagram-generator/diagram-generator.lua --lua-filter=/home/h/.wiki/filters/html-links.lua --lua-filter=/home/h/.wiki/filters/tikz.lua' +let g:markdown_composer_custom_css = ['file:///home/h/.zk/pandoc.css'] +let g:markdown_composer_external_renderer='pandoc -f markdown+latex_macros-yaml_metadata_block -t html5 --mathjax --bibliograph /home/h/.zk/references.bib --citeproc --lua-filter=/home/h/.wiki/lua-filters/diagram-generator/diagram-generator.lua --lua-filter=/home/h/.wiki/filters/html-links.lua --lua-filter=/home/h/.zk/filters/tikz.lua' let g:markdown_composer_autostart = 0 " }}} " `lervag/wiki.vim` {{{ -" Only load wiki.vim for wiki directory +" Only load wiki.vim for zk directory let g:wiki_global_load=0 -let g:wiki_root='~/.wiki' +let g:wiki_root='~/.zk' let g:wiki_index_name='index' let g:wiki_zotero_root='~/doc/Zotero' let g:wiki_filetypes=['md'] @@ -495,7 +495,7 @@ au FileType javascript set mps+==:; au BufNewFile,BufRead */.vscode/*.json setlocal filetype=jsonc " Hacky way to pass on active note to script for automated for HTML preview -au BufEnter /home/h/.wiki/*.md silent exe '!echo %:t > /home/h/.local/share/nvim/plugged/bro/current-page' +au BufEnter /home/h/.zk/*.md silent exe '!echo %:t > /home/h/.local/share/nvim/plugged/bro/current-page' " }}}