Merge branch 'master' into vim-tweaks
This commit is contained in:
@@ -94,6 +94,10 @@ nnoremap ,gcp :GitGrepCurrentPartial<CR>
|
||||
" this uses ctags. the standard way to get this is Ctrl-]
|
||||
nnoremap <silent> ,f <C-]>
|
||||
|
||||
" use ,F to jump to tag in a vertical split
|
||||
nnoremap <silent> ,F :let word=expand("<cword>")<CR>:vsp<CR>:wincmd w<cr>:exec("tag ". word)<cr>
|
||||
|
||||
|
||||
"toggle between last two buffers with Z (normally ctrl-shift-6)
|
||||
nnoremap <silent> ,z <C-^>
|
||||
|
||||
|
||||
@@ -2,7 +2,9 @@
|
||||
" (if there are multiple windows into the same buffer)
|
||||
" or kill the buffer entirely if it's the last window looking into that buffer
|
||||
function! CloseWindowOrKillBuffer()
|
||||
if(bufwinnr('%')) > 1
|
||||
let number_of_windows_to_this_buffer = len(filter(range(1, winnr('$')), "winbufnr(v:val) == bufnr('%')"))
|
||||
|
||||
if number_of_windows_to_this_buffer > 1
|
||||
wincmd c
|
||||
else
|
||||
bdelete
|
||||
|
||||
Reference in New Issue
Block a user