From 11ab367425e0bacde6bce04a4cc55bcebddb9f27 Mon Sep 17 00:00:00 2001 From: Cody Hiar Date: Tue, 10 Mar 2020 10:19:34 -0600 Subject: Updates for non dockerized neovim --- plugin/vim-options.vim | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/plugin/vim-options.vim b/plugin/vim-options.vim index 3907ddd..fbeeff8 100644 --- a/plugin/vim-options.vim +++ b/plugin/vim-options.vim @@ -53,20 +53,18 @@ au BufEnter *.py let w:m1=matchadd('ColorColumn', '\%81v', 100) au BufEnter *.py let w:m2=matchadd('Error', '\%121v', 100) au BufLeave *.py call clearmatches() -let mapleader="\" " Neovim (Docker) vs Vim if has('nvim') - nnoremap y :call system('nc -w 1 172.17.0.1 41401', @0) let $EditorDir=$HOME.'/.config/nvim/' - let $SessionDir='.vimcache' - silent! execute '!mkdir -p .vimcache/backup' else - nnoremap y :call system('nc -w 1 127.0.0.1 41401', @0) let $EditorDir=$HOME.'/.vim/' - let $SessionDir='.' endif +" Set leader +let mapleader="\" +" For easier copying +nnoremap y :call system('nc -w 1 127.0.0.1 41401', @0) " type jj to get out of insert mode inoremap jj " Ctags for python project @@ -123,11 +121,11 @@ noremap ei :!isort % noremap eb :!black % " Session saving function! SaveSession() - :mksession! $SessionDir/session.vim + :mksession! ./session.vim :echo 'Session Saved!' endfunction nnoremap ess :call SaveSession() -nnoremap esr :source $SessionDir/session.vim +nnoremap esr :source ./session.vim " Delete current file and purge buffer function! Rm() :call delete(expand('%')) | bdelete! -- cgit v1.2.3