mirror of
https://github.com/tpope/vim-fugitive.git
synced 2025-11-17 07:43:44 -05:00
Begin phasing out :Git --paginate special case
This was a mistake. I took --paginate to be the opposite of --no-pager, but it forces $PAGER over $GIT_PAGER and pager configuration. This defeats the purpose of using it as way to trick :Git into running a regular command with :terminal. References https://github.com/tpope/vim-fugitive/issues/1415
This commit is contained in:
@@ -2192,6 +2192,10 @@ function! fugitive#Command(line1, line2, range, bang, mods, arg) abort
|
||||
\ (args[0] ==# 'help' || get(args, 1, '') ==# '--help') && !s:HasOpt(args, '--web')
|
||||
return s:OpenExec((a:line2 > 0 ? a:line2 : '') . (a:line2 ? 'split' : 'edit'), a:mods, args, dir) . after
|
||||
endif
|
||||
if index(['--paginate', '-p'], args[0]) >= 0
|
||||
let paginate_warning = 'fugitive: --paginate support is deprecated. Use :terminal directly'
|
||||
let after = '|echohl WarningMsg|echo ' . string(paginate_warning) . '|echohl NONE' . after
|
||||
endif
|
||||
if s:HasOpt(args, ['add', 'checkout', 'commit', 'stage', 'stash', 'reset'], '-p', '--patch') ||
|
||||
\ s:HasOpt(args, ['add', 'clean', 'stage'], '-i', '--interactive') ||
|
||||
\ index(['--paginate', '-p'], args[0]) >= 0
|
||||
|
||||
Reference in New Issue
Block a user