diff options
-rw-r--r-- | .gitmodules | 3 | ||||
-rw-r--r-- | .vimrc | 27 | ||||
m--------- | bundle/vim-gitgutter | 0 |
3 files changed, 18 insertions, 12 deletions
diff --git a/.gitmodules b/.gitmodules index 87873438..e7e9439c 100644 --- a/.gitmodules +++ b/.gitmodules @@ -55,3 +55,6 @@ [submodule "bundle/vim-commentary"] path = bundle/vim-commentary url = https://github.com/tpope/vim-commentary.git +[submodule "bundle/vim-gitgutter"] + path = bundle/vim-gitgutter + url = https://github.com/airblade/vim-gitgutter.git diff --git a/.vimrc b/.vimrc index 653459f0..efda8070 100644 --- a/.vimrc +++ b/.vimrc @@ -99,12 +99,11 @@ let g:syntastic_auto_loc_list=2 nnoremap ' ` nnoremap ` ' -" Clear search highlights -nmap <silent> <leader>n :silent :nohlsearch<CR> +nmap <leader>n :nohlsearch<CR> -nmap <silent> <leader>s :set list!<CR> +nmap <leader>s :set list!<CR> -nmap <silent> <leader>z :set spell!<CR> +nmap <leader>z :set spell!<CR> nmap <leader>p "+p nmap <leader>P "+P @@ -116,18 +115,22 @@ nmap <leader>D "+D nmap Y y$ " Insert hard tab -imap <silent> <S-tab> <C-v><tab> +imap <S-tab> <C-v><tab> nmap Q gq -nmap <silent> <leader>b :CtrlPBuffer<CR> -nmap <silent> <leader>e :CtrlP<CR> +nmap <leader>b :CtrlPBuffer<CR> +nmap <leader>e :CtrlP<CR> -nmap <silent> <leader>gs :Gstatus<CR> -nmap <silent> <leader>gc :Gcommit<CR> -nmap <silent> <leader>gp :Git push<CR> +nmap <leader>gs :Gstatus<CR> +nmap <leader>gc :Gcommit<CR> +nmap <leader>gp :Git push<CR> -nnoremap <leader>u :GundoToggle<CR> +nmap <leader>gg :GitGutterToggle<CR> +nmap <leader>gh <Plug>GitGutterNextHunk +nmap <leader>gH <Plug>GitGutterPrevHunk + +nmap <leader>u :GundoToggle<CR> " Toggle relative/absolute numbers function! NumberToggle() @@ -138,7 +141,7 @@ function! NumberToggle() endif endfunc -nnoremap <silent> <C-n> :call NumberToggle()<cr> +nmap <C-n> :call NumberToggle()<CR> " Custom commands command! W :w diff --git a/bundle/vim-gitgutter b/bundle/vim-gitgutter new file mode 160000 +Subproject ff031d022f2123353bc93a3aa97290287c10a28 |