Last active
May 12, 2018 15:45
-
-
Save LukeMathWalker/0cad7e7efb09b5260dc23dc1c63ed919 to your computer and use it in GitHub Desktop.
NeoVim settings
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
call plug#begin('~/.local/share/nvim/site/plugged') | |
Plug 'tpope/vim-fugitive' | |
Plug 'tpope/vim-surround' | |
Plug 'scrooloose/nerdtree' | |
Plug 'vim-syntastic/syntastic' | |
Plug 'vim-airline/vim-airline' | |
Plug 'vim-airline/vim-airline-themes' | |
Plug 'flazz/vim-colorschemes' | |
Plug 'easymotion/vim-easymotion' | |
Plug 'Valloric/YouCompleteMe' | |
Plug 'ctrlpvim/ctrlp.vim' | |
Plug 'leshill/vim-json' | |
Plug 'drmingdrmer/vim-syntax-markdown' | |
Plug 'vim-python/python-syntax' | |
Plug 'ludovicchabant/vim-gutentags' | |
Plug 'tmhedberg/SimpylFold' | |
Plug 'Vimjas/vim-python-pep8-indent' | |
Plug 'bkad/CamelCaseMotion' | |
Plug 'rust-lang/rust.vim' | |
Plug 'racer-rust/vim-racer' | |
call plug#end() | |
set wildignore+=*/tmp/*,*.so,*.swp,*.zip | |
set statusline+=%#warningmsg# | |
set statusline+=%{SyntasticStatuslineFlag()} | |
set statusline+=%* | |
let g:python_pep8_indent_multiline_string = -2 | |
let g:syntastic_always_populate_loc_list = 1 | |
let g:syntastic_auto_loc_list = 2 | |
let g:syntastic_check_on_open = 1 | |
let g:syntastic_check_on_wq = 0 | |
let g:syntastic_loc_list_height = 5 | |
let g:syntastic_python_checkers = ['flake8'] | |
let g:python_highlight_all = 1 | |
syntax on | |
let g:airline_theme='bubblegum' | |
colorscheme hybrid_material | |
let mapleader="\<SPACE>" | |
set number | |
set expandtab | |
set shiftwidth=2 | |
set softtabstop=2 | |
set tabstop=2 | |
set ttimeoutlen=5 | |
set tags=tags | |
if has("autocmd") | |
" remove trailing white spaces | |
autocmd BufWritePre * :%s/\s\+$//e | |
endif | |
"split navigations | |
nnoremap <C-J> <C-W><C-J> | |
nnoremap <C-K> <C-W><C-K> | |
nnoremap <C-L> <C-W><C-L> | |
nnoremap <C-H> <C-W><C-H> | |
"Auto complete | |
let g:ycm_autoclose_preview_window_after_completion=1 | |
map <leader>g :YcmCompleter GoToDefinitionElseDeclaration | |
"Nerdtree shortcuts | |
nnoremap <Leader>t :NERDTreeToggle<Enter> | |
"Automatically close NerdTree when you open a file | |
let NERDTreeQuitOnOpen = 1 | |
"Automatically delete the buffer of the file you just deleted with NerdTree | |
let NERDTreeAutoDeleteBuffer = 1 | |
let NERDTreeMinimalUI = 1 | |
let NERDTreeDirArrows = 1 | |
"Vim-fugitive commands | |
nnoremap <Leader>gs :Gstatus<Enter> | |
nnoremap <Leader>gc :Gcommit<Enter> | |
"Camel case motion | |
call camelcasemotion#CreateMotionMappings('<leader>') | |
"Racer | |
set hidden | |
let g:racer_cmd = "/home/luca/.cargo/bin/racer" | |
"Rust c-tags | |
autocmd BufRead *.rs :setlocal tags=./rusty-tags.vi;/ | |
autocmd BufWritePost *.rs :silent! exec "!rusty-tags vi --quiet --start-dir=" . expand('%:p:h') . "&" | redraw! | |
autocmd BufRead *.rs :setlocal tags=./rusty-tags.vi;/,$RUST_SRC_PATH/rusty-tags.vi | |
"Rust syntax checking | |
let g:syntastic_rust_checkers = ['cargo'] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment