summaryrefslogtreecommitdiff
path: root/nvimrc
diff options
context:
space:
mode:
Diffstat (limited to 'nvimrc')
-rw-r--r--nvimrc22
1 files changed, 15 insertions, 7 deletions
diff --git a/nvimrc b/nvimrc
index 88938eb..b105474 100644
--- a/nvimrc
+++ b/nvimrc
@@ -22,6 +22,7 @@ Plug 'scrooloose/nerdtree'
Plug 'scrooloose/syntastic'
Plug 'SirVer/ultisnips'
Plug 'sjl/Gundo.vim'
+Plug 'szw/vim-ctrlspace'
Plug 'terryma/vim-multiple-cursors'
Plug 'tomasr/molokai'
Plug 'tommcdo/vim-exchange'
@@ -34,6 +35,7 @@ Plug 'tpope/vim-scriptease'
Plug 'tpope/vim-sensible'
Plug 'tpope/vim-surround'
Plug 'tpope/vim-unimpaired'
+Plug 'troydm/zoomwintab.vim'
Plug 'Valloric/YouCompleteMe'
call plug#end()
@@ -68,6 +70,7 @@ let g:bufferline_echo = 0
let g:bufferline_modified = '+'
let g:bufferline_rotate = 0
+nnoremap <a-p> :CtrlPMRUFiles<cr>
let g:ctrlp_by_filename = 1
let g:ctrlp_cmd = 'CtrlPBuffer'
let g:ctrlp_map = '<c-p>'
@@ -75,7 +78,11 @@ let g:ctrlp_open_new_file = 't'
let g:ctrlp_show_hidden = 1
let g:ctrlp_user_command = ['.git/', 'git --git-dir=%s/.git ls-files -oc --exclude-standard']
let g:ctrlp_working_path_mode = 'r'
-nnoremap <a-p> :CtrlPMRUFiles<cr>
+let g:ctrlp_prompt_mappings = {
+ \ 'PrtSelectMove("j")': ['<c-n>'],
+ \ 'PrtSelectMove("k")': ['<c-p>'],
+ \ 'PrtHistory(-1)': ['<c-j>'],
+ \ 'PrtHistory(1)': ['<c-k>'],}
let g:syntastic_cpp_compiler = "g++"
let g:syntastic_cpp_compiler_options = "-std=c++11 -Wall -Wextra -Wpedantic"
@@ -195,11 +202,11 @@ nnoremap <Leader>sc :source %<cr>
" File edits
nnoremap <Leader>es :UltiSnipsEdit<cr>
-nnoremap <Leader>em :e ~/.mutt/muttrc<cr>
-nnoremap <Leader>en :e ~/.nvimrc<cr>
-nnoremap <Leader>ev :e ~/.vimrc<cr>
-nnoremap <Leader>ez :e ~/.zshrc<cr>
-nnoremap <Leader>et :e ~/.tmux.conf<cr>
+nnoremap <Leader>em :e ~/dotfiles/mutt/muttrc<cr>
+nnoremap <Leader>en :e ~/dotfiles/nvimrc<cr>
+nnoremap <Leader>ev :e ~/dotfiles/vimrc<cr>
+nnoremap <Leader>ez :e ~/dotfiles/zshrc<cr>
+nnoremap <Leader>et :e ~/dotfiles/tmux.conf<cr>
" Formatting
nnoremap <Leader>fw :%s/\s\+$//<cr>
@@ -240,10 +247,11 @@ vnoremap , :
" Neovim specific
tmap <C-_> <C-\><C-n><C-^>
nnoremap <C-_> :b term<cr>i
-inoremap <C-_> <Esc><C-^>i
+inoremap <C-_> <Esc>:b term<cr>i
"" Restore cursor position
augroup autocommands
+ au!
autocmd BufWritePost *.cpp Neomake!
autocmd BufReadPost *
\ if line("'\"") > 1 && line("'\"") <= line("$") |