~antoinentl/vimrc

97bfb022d798bdee122457b2ca4d4578840dc2d8 — antoinentl 2 years ago
admin: init
1 files changed, 63 insertions(+), 0 deletions(-)

A vimrc
A  => vimrc +63 -0
@@ 1,63 @@
let data_dir = has('nvim') ? stdpath('data') . '/site' : '~/.vim'
if empty(glob(data_dir . '/autoload/plug.vim'))
  silent execute '!curl -fLo '.data_dir.'/autoload/plug.vim --create-dirs  https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
  autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
endif

" Plugins will be downloaded under the specified directory.
call plug#begin(expand('~/.vim/plugins'))

" Declare the list of plugins.
Plug 'arcticicestudio/nord-vim'
Plug 'preservim/nerdtree' |
            \ Plug 'xuyuanp/nerdtree-git-plugin'

" List ends here. Plugins become visible to Vim after this call.
call plug#end()

let g:nord_italic_comments = 1
let g:nord_cursor_line_number_background = 1
let g:nord_uniform_status_lines = 1
let g:nord_bold = 1
let g:nord_italic = 1
"colorscheme nord
set number
set numberwidth=2

" Start NERDTree and put the cursor back in the other window.
autocmd VimEnter * NERDTree | wincmd p
let g:NERDTreeWinSize=50

set linebreak
set termwinsize=10x0
set viminfo+=n~/.vim/viminfo

" Autorefresh nerdtree
autocmd BufWritePost * NERDTreeFocus | execute 'normal R' | wincmd p

" Show hidden files in nerdtree
let NERDTreeShowHidden=1

" Check language
setlocal spell
setlocal spelllang=fr,en
setlocal spellfile=$HOME/.vim/spell/fr.utf-8.add,$HOME/.vim/spell/en.utf-8.add

" Spell check graphic config
hi clear SpellBad
hi clear SpellCap
hi clear SpellRare
hi clear SpellLocal
hi SpellBad   cterm=underline ctermfg=9  ctermbg=0 gui=undercurl
hi SpellCap   cterm=underline ctermfg=14 ctermbg=0 gui=undercurl
hi SpellRare  cterm=underline ctermfg=13 ctermbg=0 gui=undercurl
hi SpellLocal cterm=underline ctermfg=11 ctermbg=0 gui=undercurl

" Navigation by lines displayed on the screen
nnoremap j gj
nnoremap <Down> gj
nnoremap k gk
nnoremap <Up> gk

" Copy paste for external use
set clipboard=unnamedplus