.nvim for non config files
This commit is contained in:
parent
1eebf73e75
commit
23036deb6f
4
init.vim
4
init.vim
|
@ -119,14 +119,14 @@ let g:WebDevIconsNerdTreeGitPluginForceVAlign = 1
|
||||||
|
|
||||||
" BACKUPS ###########################################################{{{
|
" BACKUPS ###########################################################{{{
|
||||||
set dir=$HOME/.nvim/swp//
|
set dir=$HOME/.nvim/swp//
|
||||||
autocmd BufWritePost * :silent execute ':w! ' ."$HOME/.config/nvim/backups/" . substitute(escape(substitute(expand('%:p'), "/", "%", "g"), "%"), ' ', '\\ ', 'g')
|
autocmd BufWritePost * :silent execute ':w! ' ."$HOME/.nvim/backups/" . substitute(escape(substitute(expand('%:p'), "/", "%", "g"), "%"), ' ', '\\ ', 'g')
|
||||||
|
|
||||||
if exists('+undofile')
|
if exists('+undofile')
|
||||||
set undofile
|
set undofile
|
||||||
set undolevels=1000
|
set undolevels=1000
|
||||||
set undoreload=10000
|
set undoreload=10000
|
||||||
if exists('+undodir')
|
if exists('+undodir')
|
||||||
set undodir=$HOME/.config/nvim/undo
|
set undodir=$HOME/.nvim/undo
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
" }}}
|
" }}}
|
||||||
|
|
|
@ -6,7 +6,7 @@ if [ -f $1 ]; then
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
backup_path=~/.config/nvim/backups/`echo $PWD/$1 | tr '/' '%'`
|
backup_path=~/.nvim/backups/`echo $PWD/$1 | tr '/' '%'`
|
||||||
|
|
||||||
if [ ! -f "$backup_path" ]; then
|
if [ ! -f "$backup_path" ]; then
|
||||||
echo >&2 Backup not found...
|
echo >&2 Backup not found...
|
||||||
|
|
Loading…
Reference in New Issue