summaryrefslogtreecommitdiff
path: root/nvim/init.vim
diff options
context:
space:
mode:
authorzachir <zachir@librem.one>2025-01-20 16:19:53 -0600
committerzachir <zachir@librem.one>2025-01-20 16:19:53 -0600
commit021b916382f129d8e95a5070fbbf466a05c2582a (patch)
tree4455e2185dde7c8d0365dc6ecf39083166192518 /nvim/init.vim
parentc1e2ed7f2bbef1879093c19ddd79787b3d671aff (diff)
Use the same config for both vim and nvim
This was already taken care of in the config, I'm not sure why I didn't do this at the time.
Diffstat (limited to 'nvim/init.vim')
-rw-r--r--nvim/init.vim17
1 files changed, 17 insertions, 0 deletions
diff --git a/nvim/init.vim b/nvim/init.vim
index d27d9d4..cdf9b33 100644
--- a/nvim/init.vim
+++ b/nvim/init.vim
@@ -1,3 +1,20 @@
+set runtimepath^=$XDG_CONFIG_HOME/vim
+set runtimepath+=$XDG_DATA_HOME/vim
+set runtimepath+=$XDG_CONFIG_HOME/vim/after
+
+set packpath^=$XDG_DATA_HOME/vim,$XDG_CONFIG_HOME/vim
+set packpath+=$XDG_CONFIG_HOME/vim/after,$XDG_DATA_HOME/vim/after
+
+let g:netrw_home = $XDG_DATA_HOME."/vim"
+call mkdir($XDG_DATA_HOME."/vim/spell", 'p')
+
+set backupdir=$XDG_STATE_HOME/vim/backup | call mkdir(&backupdir, 'p')
+set directory=$XDG_STATE_HOME/vim/swap | call mkdir(&directory, 'p')
+set undodir=$XDG_STATE_HOME/vim/undo | call mkdir(&undodir, 'p')
+set viewdir=$XDG_STATE_HOME/vim/view | call mkdir(&viewdir, 'p')
+
+if !has('nvim') | set viminfofile=$XDG_STATE_HOME/vim/viminfo | endif
+
" vimplugs {{{
call plug#begin('~/.config/nvim/plugged')
" colorschemes {{{