mirror of
https://github.com/junegunn/vim-plug.git
synced 2025-12-06 09:04:23 +08:00
Keep track of the default branch of the origin (#1272)
Fix #1005 vim-plug will now run `git remote set-head origin -a` on PlugUpdate to keep track of the default branch of the origin, so that it can still update a plugin even if its default branch has changed. This additional command will slow down the update process, but this is an unavoidable price to pay for the correctness of the task. However, vim-plug will run checkout and merge commands in parallel, so this improvement will slightly offset the slowdown.
This commit is contained in:
@@ -983,7 +983,8 @@ Execute (PlugInstall!):
|
||||
Assert filereadable(g:plugs['vim-easy-align'].dir.'/installed2'),
|
||||
\ 'vim-easy-align/installed2 should exist'
|
||||
AssertEqual '7f8cd78cb1fe52185b98b16a3749811f0cc508af', GitCommit('vim-pseudocl')
|
||||
AssertEqual 'no-t_co', GitBranch('seoul256.vim')
|
||||
" Was updated to the default branch of origin by previous PlugUpdate
|
||||
AssertEqual 'master', GitBranch('seoul256.vim')
|
||||
AssertEqual '1.5.3', GitTag('goyo.vim')
|
||||
|
||||
Execute (When submodules are not initialized):
|
||||
|
||||
Reference in New Issue
Block a user