parent
1b0ddad697
commit
546a6bf219
@ -1500,14 +1500,14 @@ function! s:Diff(bang,...)
|
|||||||
try
|
try
|
||||||
let spec = s:repo().translate(file)
|
let spec = s:repo().translate(file)
|
||||||
let commit = matchstr(spec,'\C[^:/]//\zs\x\+')
|
let commit = matchstr(spec,'\C[^:/]//\zs\x\+')
|
||||||
|
let restore = s:diff_restore()
|
||||||
|
let w:fugitive_diff_restore = restore
|
||||||
if s:buffer().compare_age(commit) < 0
|
if s:buffer().compare_age(commit) < 0
|
||||||
execute 'rightbelow '.vert.'split '.s:fnameescape(spec)
|
execute 'rightbelow '.vert.'diffsplit '.s:fnameescape(spec)
|
||||||
else
|
else
|
||||||
execute 'leftabove '.vert.'split '.s:fnameescape(spec)
|
execute 'leftabove '.vert.'diffsplit '.s:fnameescape(spec)
|
||||||
endif
|
endif
|
||||||
call s:diffthis()
|
let w:fugitive_diff_restore = restore
|
||||||
wincmd p
|
|
||||||
call s:diffthis()
|
|
||||||
return ''
|
return ''
|
||||||
catch /^fugitive:/
|
catch /^fugitive:/
|
||||||
return 'echoerr v:errmsg'
|
return 'echoerr v:errmsg'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user