Don't overwrite paste buffer in :Gread

This commit is contained in:
Tim Pope 2010-12-27 23:50:32 -05:00
parent ab35c2d9ab
commit 64ead8ea1c

View File

@ -860,7 +860,7 @@ function! s:Edit(cmd,...) abort
if a:cmd =~# '!$'
call s:warn(':Gread! is deprecated. Use :Gread')
endif
return 'silent %delete|read '.s:fnameescape(file).'|silent 1delete_|diffupdate|'.line('.')
return 'silent %delete_|read '.s:fnameescape(file).'|silent 1delete_|diffupdate|'.line('.')
else
if &previewwindow && getbufvar('','fugitive_type') ==# 'index'
wincmd p