diff options
author | Mike Gilbert <floppym@gentoo.org> | 2016-11-03 15:22:31 -0400 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2016-11-03 13:04:35 -0700 |
commit | d075422a8902617833ec945d94beb0bb334d44c9 (patch) | |
tree | 7124bb7961cc9da445db07550cd7a50731037688 | |
parent | [sync] Run `git update-index --refresh` when doing shallow pulls (diff) | |
download | portage-d075422a.tar.gz portage-d075422a.tar.bz2 portage-d075422a.zip |
sync: always pass -q --unmerged to git-update-index
Passing -q --unmerged prevents update-index from erroring out when local
file changes are present.
From git-update-index(1):
-q
Quiet. If --refresh finds that the index needs an update, the
default behavior is to error out. This option makes git
update-index continue anyway.
--unmerged
If --refresh finds unmerged changes in the index, the default
behavior is to error out. This option makes git update-index
continue anyway.
X-Gentoo-Bug-URL: https://bugs.gentoo.org/552814#c58
Acked-by: Brian Dolbec <dolsen@gentoo.org>
-rw-r--r-- | pym/portage/sync/modules/git/git.py | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/pym/portage/sync/modules/git/git.py b/pym/portage/sync/modules/git/git.py index dc94ec93f..f288733ac 100644 --- a/pym/portage/sync/modules/git/git.py +++ b/pym/portage/sync/modules/git/git.py @@ -118,10 +118,7 @@ class GitSync(NewBase): if exitcode == os.EX_OK and self.repo.sync_depth is not None: # update-index --refresh is needed on some filesystems # (e.g. with overlayfs on squashfs) - update_index_cmd = [self.bin_command, 'update-index'] - if quiet: # -q needs to go first - update_index_cmd.append('-q') - update_index_cmd.append('--refresh') + update_index_cmd = [self.bin_command, 'update-index', '-q', '--unmerged', '--refresh'] exitcode = subprocess.call(update_index_cmd, cwd=portage._unicode_encode(self.repo.location)) |