From 078210c7186bf4f32ff211eef8662177b3bed919 Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Sun, 11 Aug 2019 18:12:12 -0400 Subject: [PATCH] Use temp buffer for :Git show and :Git stash show --- autoload/fugitive.vim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/autoload/fugitive.vim b/autoload/fugitive.vim index 0dd6d0c..5bc604f 100644 --- a/autoload/fugitive.vim +++ b/autoload/fugitive.vim @@ -2129,7 +2129,8 @@ function! s:GitCommand(line1, line2, range, count, bang, mods, reg, arg, args) a return 'echoerr ' . string(v:exception) endtry endif - if a:bang || args[0] =~# '^-P$\|^--no-pager$\|diff\%(tool\)\@!\|log' + if a:bang || args[0] =~# '^-P$\|^--no-pager$\|diff\%(tool\)\@!\|log\|^show$' || + \ (args[0] ==# 'stash' && get(args, 1, '') ==# 'show') return s:OpenExec((a:count > 0 ? a:count : '') . (a:count ? 'split' : 'edit'), a:mods, args, dir) . after endif let git = s:UserCommandList(dir)