mirror of
https://github.com/tpope/vim-fugitive.git
synced 2025-11-16 07:13:52 -05:00
Make "q" error maps consistent
This commit is contained in:
@@ -2729,7 +2729,7 @@ function! fugitive#BufReadStatus() abort
|
||||
call s:Map('n', 'I', ":<C-U>execute <SID>StagePatch(line('.'),line('.'))<CR>", '<silent>')
|
||||
call s:Map('x', 'I', ":<C-U>execute <SID>StagePatch(line(\"'<\"),line(\"'>\"))<CR>", '<silent>')
|
||||
if empty(mapcheck('q', 'n'))
|
||||
nnoremap <buffer> <silent> q :echoerr "fugitive: q removed in favor of gq (or :q)"<CR>
|
||||
nnoremap <buffer> <silent> q :<C-U>echoerr "fugitive: q is removed in favor of gq (or :q)"<CR>
|
||||
endif
|
||||
call s:Map('n', 'gq', ":<C-U>if bufnr('$') == 1<Bar>quit<Bar>else<Bar>bdelete<Bar>endif<CR>", '<silent>')
|
||||
call s:Map('n', 'R', ":echohl WarningMsg<Bar>echo 'Reloading is automatic. Use :e to force'<Bar>echohl NONE<CR>", '<silent>')
|
||||
@@ -6901,8 +6901,8 @@ function! fugitive#BlameFileType() abort
|
||||
endif
|
||||
call s:Map('n', '<F1>', ':help :Git_blame<CR>', '<silent>')
|
||||
call s:Map('n', 'g?', ':help :Git_blame<CR>', '<silent>')
|
||||
if mapcheck('q', 'n') =~# '^$\|bdelete'
|
||||
call s:Map('n', 'q', ':echoerr "fugitive: q removed in favor of gq (or :q)"<CR>', '<silent>')
|
||||
if empty(mapcheck('q', 'n'))
|
||||
nnoremap <buffer> <silent> q :<C-U>echoerr "fugitive: q removed in favor of gq (or :q)"<CR>
|
||||
endif
|
||||
call s:Map('n', 'gq', ':exe <SID>BlameQuit()<CR>', '<silent>')
|
||||
call s:Map('n', '<2-LeftMouse>', ':<C-U>exe <SID>BlameCommit("exe <SID>BlameLeave()<Bar>edit")<CR>', '<silent>')
|
||||
|
||||
Reference in New Issue
Block a user