From 09e11d7a2c357c473dfc3b7bf8d3c3fa33d049f1 Mon Sep 17 00:00:00 2001 From: spinach <19keegandeppe@gmail.com> Date: Sat, 25 Feb 2023 13:03:06 -0500 Subject: [PATCH] added i3 scratchpad changes and some vim nerdtree and transparent background changes --- .gitmodules | 3 +++ editors/vim/pack/man/start/vim-markdown | 2 +- editors/vim/pack/man/start/vim-nerdtree-tabs | 1 + editors/vim/pack/man/start/vimtex | 2 +- editors/vim/vimrc | 24 ++++++++++++++++++-- gui/i3/base.conf | 4 ++-- 6 files changed, 30 insertions(+), 6 deletions(-) create mode 160000 editors/vim/pack/man/start/vim-nerdtree-tabs diff --git a/.gitmodules b/.gitmodules index 2e2a69b..a4cf238 100644 --- a/.gitmodules +++ b/.gitmodules @@ -32,6 +32,9 @@ [submodule "vimtex"] path = editors/vim/pack/man/start/vimtex url = https://github.com/lervag/vimtex.git +[submodule "vim-nerdtree-tabs"] + path = editors/vim/pack/man/start/vim-nerdtree-tabs + url = https://github.com/jistr/vim-nerdtree-tabs [submodule "tmux-mem-cpu-load"] path = src/tmux-mem-cpu-load url = https://github.com/thewtex/tmux-mem-cpu-load diff --git a/editors/vim/pack/man/start/vim-markdown b/editors/vim/pack/man/start/vim-markdown index df4be86..5d3d1b6 160000 --- a/editors/vim/pack/man/start/vim-markdown +++ b/editors/vim/pack/man/start/vim-markdown @@ -1 +1 @@ -Subproject commit df4be8626e2c5b2a42eb60e1f100fce469b81f7d +Subproject commit 5d3d1b6cbdc4be0b4c6105c1ab1f769d76d3c68f diff --git a/editors/vim/pack/man/start/vim-nerdtree-tabs b/editors/vim/pack/man/start/vim-nerdtree-tabs new file mode 160000 index 0000000..07d19f0 --- /dev/null +++ b/editors/vim/pack/man/start/vim-nerdtree-tabs @@ -0,0 +1 @@ +Subproject commit 07d19f0299762669c6f93fbadb8249da6ba9de62 diff --git a/editors/vim/pack/man/start/vimtex b/editors/vim/pack/man/start/vimtex index 6e79c4f..b09112b 160000 --- a/editors/vim/pack/man/start/vimtex +++ b/editors/vim/pack/man/start/vimtex @@ -1 +1 @@ -Subproject commit 6e79c4fa42ef0eb5216220afe835be8fe9d2369d +Subproject commit b09112bf83ae5e308102a9c07d25f7dba6690675 diff --git a/editors/vim/vimrc b/editors/vim/vimrc index 2b633dd..64d96ff 100644 --- a/editors/vim/vimrc +++ b/editors/vim/vimrc @@ -17,6 +17,20 @@ set nocompatible set background=dark syntax enable colorscheme hybrid +" default transparent bg +hi Normal guibg=NONE ctermbg=NONE +let t:is_transparent = 1 +"toggle func +function! ToggleTransparent() + if t:is_transparent == 0 + hi Normal guibg=NONE ctermbg=NONE + let t:is_transparent = 1 + else + set background=dark + let t:is_transparent = 0 + endif +endfunction +nnoremap b : call ToggleTransparent() " syntax highlighting for go let g:go_highlight_types=1 @@ -30,6 +44,7 @@ let g:go_highlight_extra_types=1 let g:vim_markdown_folding_disabled = 1 let g:vim_markdown_math = 1 let g:vim_markdown_strikethrough = 1 +let g:vim_markdown_new_list_item_indent = 4 " use md for vim wiki and disable global linking let g:vimwiki_list = [{'path': '~/vimwiki/', @@ -54,6 +69,11 @@ let g:airline_symbols.dirty = '' " nerdtree settings let NERDTreeHighlightCursorLine=1 let NERDTreeQuitOnOpen=1 +" nerdtree tab settings +let g:nerdtree_tabs_open_on_console_startup=2 +let g:nerdtree_tabs_autoclose=1 +let g:nerdtree_tabs_smart_startup_focus=1 +"let g:nerd autocmd StdinReadPre * let s:std_in=1 " auto open on empty autocmd VimEnter * if argc() == 0 && !exists("s:std_in") | NERDTree | endif @@ -62,8 +82,8 @@ autocmd BufEnter * if bufname('#') =~ 'NERD_tree_\d\+' && bufname('%') !~ 'NERD_ \ let buf=bufnr() | buffer# | execute "normal! \w" | execute 'buffer'.buf | endif " nerdtree binds -nnoremap n :NERDTree -nnoremap t :NERDTreeMirror:NERDTreeToggle +nnoremap t :NERDTreeMirrorToggle +nnoremap n :NERDTreeFocusToggle " nnoremap :NERDTreeFocus going to conflict with fzf and I dont use " this anyway " diff --git a/gui/i3/base.conf b/gui/i3/base.conf index 8c092c8..a14ed64 100644 --- a/gui/i3/base.conf +++ b/gui/i3/base.conf @@ -55,9 +55,9 @@ for_window [instance="cal"] move window to scratchpad for_window [instance="spotify"] move window to scratchpad for_window [instance="wiki"] move window to scratchpad # bindings -bindsym $mod+s exec i3-scratchpad.sh todo st -n todo -e vim ~/vimwiki/todo/index.md +bindsym $mod+x exec i3-scratchpad.sh todo st -n todo -e vim ~/vimwiki/todo/index.md bindsym $mod+c exec i3-scratchpad.sh cal st -n cal -e calcurse -bindsym $mod+m exec i3-scratchpad.sh spotify spotify +bindsym $mod+s exec i3-scratchpad.sh spotify spotify bindsym $mod+w exec i3-scratchpad.sh wiki st -n wiki -e vim ~/vimwiki/index.md