Skip to content

Commit

Permalink
Preserve alternate file in :Gmove
Browse files Browse the repository at this point in the history
  • Loading branch information
tpope committed Apr 22, 2011
1 parent 3ad9b0d commit 68b3f3b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions plugin/fugitive.vim
Expand Up @@ -1178,9 +1178,9 @@ function! s:Move(force,destination)
call fugitive#reload_status()
if s:buffer().commit() == ''
if isdirectory(destination)
return 'edit '.s:fnameescape(destination)
return 'keepalt edit '.s:fnameescape(destination)
else
return 'saveas! '.s:fnameescape(destination)
return 'keepalt saveas! '.s:fnameescape(destination)
endif
else
return 'file '.s:fnameescape(s:repo().translate(':0:'.destination)
Expand Down

0 comments on commit 68b3f3b

Please sign in to comment.