Switch :Gblame <CR> to open commit

This is more useful than the previous behavior of reblaming at that
commit.  Said behavior is still available on -.
This commit is contained in:
Tim Pope
2013-01-30 16:00:41 -05:00
parent 1bce4328e4
commit cf3fe781dd
2 changed files with 2 additions and 2 deletions

View File

@@ -182,7 +182,7 @@ that are part of Git repositories).
D resize to end of date/time column
q close blame and return to blamed window
gq q, then |:Gedit| to return to work tree version
i q, then open commit
<CR> q, then open commit
o open commit in horizontal split
O open commit in new tab
- reblame at commit

View File

@@ -1631,7 +1631,7 @@ function! s:Blame(bang,line1,line2,count,args) abort
execute "vertical resize ".(s:linechars('.\{-\}\ze\s\+\d\+)')+1)
nnoremap <buffer> <silent> q :exe substitute(bufwinnr(b:fugitive_blamed_bufnr).' wincmd w<Bar>'.bufnr('').'bdelete','^-1','','')<CR>
nnoremap <buffer> <silent> gq :exe substitute(bufwinnr(b:fugitive_blamed_bufnr).' wincmd w<Bar>'.bufnr('').'bdelete<Bar>if expand("%:p") =~# "^fugitive:[\\/][\\/]"<Bar>Gedit<Bar>endif','^-1','','')<CR>
nnoremap <buffer> <silent> <CR> :<C-U>exe <SID>BlameJump('')<CR>
nnoremap <buffer> <silent> <CR> :<C-U>exe <SID>BlameCommit("exe 'norm q'<Bar>edit")<CR>
nnoremap <buffer> <silent> - :<C-U>exe <SID>BlameJump('')<CR>
nnoremap <buffer> <silent> P :<C-U>exe <SID>BlameJump('^'.v:count1)<CR>
nnoremap <buffer> <silent> ~ :<C-U>exe <SID>BlameJump('~'.v:count1)<CR>