* [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index @ 2016-11-02 21:09 Mike Gilbert 2016-11-03 0:17 ` Zac Medico 0 siblings, 1 reply; 11+ messages in thread From: Mike Gilbert @ 2016-11-02 21:09 UTC (permalink / raw To: gentoo-portage-dev The -q option allows git-update-index to succeed even if there are locally modified files present. X-Gentoo-Bug-URL: https://bugs.gentoo.org/552814#c58 --- pym/portage/sync/modules/git/git.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/pym/portage/sync/modules/git/git.py b/pym/portage/sync/modules/git/git.py index dc94ec9..3db6dc1 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', '--refresh'] exitcode = subprocess.call(update_index_cmd, cwd=portage._unicode_encode(self.repo.location)) -- 2.10.2 ^ permalink raw reply related [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index 2016-11-02 21:09 [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index Mike Gilbert @ 2016-11-03 0:17 ` Zac Medico 2016-11-03 4:57 ` Zac Medico 0 siblings, 1 reply; 11+ messages in thread From: Zac Medico @ 2016-11-03 0:17 UTC (permalink / raw To: gentoo-portage-dev On 11/02/2016 02:09 PM, Mike Gilbert wrote: > The -q option allows git-update-index to succeed even if there are > locally modified files present. > > X-Gentoo-Bug-URL: https://bugs.gentoo.org/552814#c58 > --- > pym/portage/sync/modules/git/git.py | 5 +---- > 1 file changed, 1 insertion(+), 4 deletions(-) > > diff --git a/pym/portage/sync/modules/git/git.py b/pym/portage/sync/modules/git/git.py > index dc94ec9..3db6dc1 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', '--refresh'] > > exitcode = subprocess.call(update_index_cmd, > cwd=portage._unicode_encode(self.repo.location)) > LGTM. I just checked the man page, and this behavior is documented there: -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. -- Thanks, Zac ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index 2016-11-03 0:17 ` Zac Medico @ 2016-11-03 4:57 ` Zac Medico 2016-11-03 6:17 ` Brian Dolbec 2016-11-03 19:22 ` [gentoo-portage-dev] [PATCH] sync: always pass -q --unmerged " Mike Gilbert 0 siblings, 2 replies; 11+ messages in thread From: Zac Medico @ 2016-11-03 4:57 UTC (permalink / raw To: gentoo-portage-dev On 11/02/2016 05:17 PM, Zac Medico wrote: > On 11/02/2016 02:09 PM, Mike Gilbert wrote: >> The -q option allows git-update-index to succeed even if there are >> locally modified files present. >> >> X-Gentoo-Bug-URL: https://bugs.gentoo.org/552814#c58 >> --- >> pym/portage/sync/modules/git/git.py | 5 +---- >> 1 file changed, 1 insertion(+), 4 deletions(-) >> >> diff --git a/pym/portage/sync/modules/git/git.py b/pym/portage/sync/modules/git/git.py >> index dc94ec9..3db6dc1 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', '--refresh'] >> >> exitcode = subprocess.call(update_index_cmd, >> cwd=portage._unicode_encode(self.repo.location)) >> > > LGTM. > > I just checked the man page, and this behavior is documented there: > > -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. > Actually we should probably add --unmerged, as suggested numerous times by Martin Väth. -- Thanks, Zac ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index 2016-11-03 4:57 ` Zac Medico @ 2016-11-03 6:17 ` Brian Dolbec 2016-11-03 16:10 ` Zac Medico 2016-11-03 19:22 ` [gentoo-portage-dev] [PATCH] sync: always pass -q --unmerged " Mike Gilbert 1 sibling, 1 reply; 11+ messages in thread From: Brian Dolbec @ 2016-11-03 6:17 UTC (permalink / raw To: gentoo-portage-dev On Wed, 2 Nov 2016 21:57:09 -0700 Zac Medico <zmedico@gentoo.org> wrote: > On 11/02/2016 05:17 PM, Zac Medico wrote: > > On 11/02/2016 02:09 PM, Mike Gilbert wrote: > >> The -q option allows git-update-index to succeed even if there are > >> locally modified files present. > >> > >> X-Gentoo-Bug-URL: https://bugs.gentoo.org/552814#c58 > >> --- > >> pym/portage/sync/modules/git/git.py | 5 +---- > >> 1 file changed, 1 insertion(+), 4 deletions(-) > >> > >> diff --git a/pym/portage/sync/modules/git/git.py > >> b/pym/portage/sync/modules/git/git.py index dc94ec9..3db6dc1 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', '--refresh'] > >> exitcode = > >> subprocess.call(update_index_cmd, > >> cwd=portage._unicode_encode(self.repo.location)) > > > > LGTM. > > > > I just checked the man page, and this behavior is documented there: > > > > -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. > > > > Actually we should probably add --unmerged, as suggested numerous > times by Martin Väth. I suspect we won't hear the end of our breakage of a perfectly working git module until maybe we add enough git-sync-options configurable in repos.conf to account for every possible file system and every possible repo useage/abuse-age... Maybe we should just ship several versions of a git module... one for every use case ;) (kidding) -- Brian Dolbec <dolsen> ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index 2016-11-03 6:17 ` Brian Dolbec @ 2016-11-03 16:10 ` Zac Medico 2016-11-03 17:03 ` Brian Dolbec 0 siblings, 1 reply; 11+ messages in thread From: Zac Medico @ 2016-11-03 16:10 UTC (permalink / raw To: gentoo-portage-dev On 11/02/2016 11:17 PM, Brian Dolbec wrote: > On Wed, 2 Nov 2016 21:57:09 -0700 > Zac Medico <zmedico@gentoo.org> wrote: > >> On 11/02/2016 05:17 PM, Zac Medico wrote: >>> On 11/02/2016 02:09 PM, Mike Gilbert wrote: >>>> The -q option allows git-update-index to succeed even if there are >>>> locally modified files present. >>>> >>>> X-Gentoo-Bug-URL: https://bugs.gentoo.org/552814#c58 >>>> --- >>>> pym/portage/sync/modules/git/git.py | 5 +---- >>>> 1 file changed, 1 insertion(+), 4 deletions(-) >>>> >>>> diff --git a/pym/portage/sync/modules/git/git.py >>>> b/pym/portage/sync/modules/git/git.py index dc94ec9..3db6dc1 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', '--refresh'] >>>> exitcode = >>>> subprocess.call(update_index_cmd, >>>> cwd=portage._unicode_encode(self.repo.location)) >>> >>> LGTM. >>> >>> I just checked the man page, and this behavior is documented there: >>> >>> -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. >>> >> >> Actually we should probably add --unmerged, as suggested numerous >> times by Martin Väth. > > I suspect we won't hear the end of our breakage of a perfectly working > git module until maybe we add enough git-sync-options configurable in > repos.conf to account for every possible file system and every possible > repo useage/abuse-age... > > > Maybe we should just ship several versions of a git module... one for > every use case ;) (kidding) Well the Funtoo people are disproportionately affected by anything we do to this module, so we can expect to hear them complain loudly when it breaks. We shouldn't let that stop us from adding important new features though. I think Martin Väth is on the right track in suggesting that we use `git update-index -q --unmerged` like git status does. -- Thanks, Zac ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index 2016-11-03 16:10 ` Zac Medico @ 2016-11-03 17:03 ` Brian Dolbec 2016-11-03 17:27 ` Zac Medico 0 siblings, 1 reply; 11+ messages in thread From: Brian Dolbec @ 2016-11-03 17:03 UTC (permalink / raw To: gentoo-portage-dev On Thu, 3 Nov 2016 09:10:14 -0700 Zac Medico <zmedico@gentoo.org> wrote: > On 11/02/2016 11:17 PM, Brian Dolbec wrote: > > On Wed, 2 Nov 2016 21:57:09 -0700 > > Zac Medico <zmedico@gentoo.org> wrote: > > > >> On 11/02/2016 05:17 PM, Zac Medico wrote: > >>> On 11/02/2016 02:09 PM, Mike Gilbert wrote: > >>>> The -q option allows git-update-index to succeed even if there > >>>> are locally modified files present. > >>>> > >>>> X-Gentoo-Bug-URL: https://bugs.gentoo.org/552814#c58 > >>>> --- > >>>> pym/portage/sync/modules/git/git.py | 5 +---- > >>>> 1 file changed, 1 insertion(+), 4 deletions(-) > >>>> > >>>> diff --git a/pym/portage/sync/modules/git/git.py > >>>> b/pym/portage/sync/modules/git/git.py index dc94ec9..3db6dc1 > >>>> 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', '--refresh'] > >>>> exitcode = > >>>> subprocess.call(update_index_cmd, > >>>> cwd=portage._unicode_encode(self.repo.location)) > >>> > >>> LGTM. > >>> > >>> I just checked the man page, and this behavior is documented > >>> there: > >>> > >>> -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. > >>> > >> > >> Actually we should probably add --unmerged, as suggested numerous > >> times by Martin Väth. > > > > I suspect we won't hear the end of our breakage of a perfectly > > working git module until maybe we add enough git-sync-options > > configurable in repos.conf to account for every possible file > > system and every possible repo useage/abuse-age... > > > > > > Maybe we should just ship several versions of a git module... one > > for every use case ;) (kidding) > > Well the Funtoo people are disproportionately affected by anything we > do to this module, so we can expect to hear them complain loudly when > it breaks. We shouldn't let that stop us from adding important new > features though. I think Martin Väth is on the right track in > suggesting that we use `git update-index -q --unmerged` like git > status does. yes, But I have also told them from the start, with this plug-in system, they can easily add their own custom git module that fits their exact needs. -- Brian Dolbec <dolsen> ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index 2016-11-03 17:03 ` Brian Dolbec @ 2016-11-03 17:27 ` Zac Medico 0 siblings, 0 replies; 11+ messages in thread From: Zac Medico @ 2016-11-03 17:27 UTC (permalink / raw To: gentoo-portage-dev On 11/03/2016 10:03 AM, Brian Dolbec wrote: > On Thu, 3 Nov 2016 09:10:14 -0700 > Zac Medico <zmedico@gentoo.org> wrote: > >> On 11/02/2016 11:17 PM, Brian Dolbec wrote: >>> On Wed, 2 Nov 2016 21:57:09 -0700 >>> Zac Medico <zmedico@gentoo.org> wrote: >>> >>>> On 11/02/2016 05:17 PM, Zac Medico wrote: >>>>> On 11/02/2016 02:09 PM, Mike Gilbert wrote: >>>>>> The -q option allows git-update-index to succeed even if there >>>>>> are locally modified files present. >>>>>> >>>>>> X-Gentoo-Bug-URL: https://bugs.gentoo.org/552814#c58 >>>>>> --- >>>>>> pym/portage/sync/modules/git/git.py | 5 +---- >>>>>> 1 file changed, 1 insertion(+), 4 deletions(-) >>>>>> >>>>>> diff --git a/pym/portage/sync/modules/git/git.py >>>>>> b/pym/portage/sync/modules/git/git.py index dc94ec9..3db6dc1 >>>>>> 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', '--refresh'] >>>>>> exitcode = >>>>>> subprocess.call(update_index_cmd, >>>>>> cwd=portage._unicode_encode(self.repo.location)) >>>>> >>>>> LGTM. >>>>> >>>>> I just checked the man page, and this behavior is documented >>>>> there: >>>>> >>>>> -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. >>>>> >>>> >>>> Actually we should probably add --unmerged, as suggested numerous >>>> times by Martin Väth. >>> >>> I suspect we won't hear the end of our breakage of a perfectly >>> working git module until maybe we add enough git-sync-options >>> configurable in repos.conf to account for every possible file >>> system and every possible repo useage/abuse-age... >>> >>> >>> Maybe we should just ship several versions of a git module... one >>> for every use case ;) (kidding) >> >> Well the Funtoo people are disproportionately affected by anything we >> do to this module, so we can expect to hear them complain loudly when >> it breaks. We shouldn't let that stop us from adding important new >> features though. I think Martin Väth is on the right track in >> suggesting that we use `git update-index -q --unmerged` like git >> status does. > > yes, But I have also told them from the start, with this plug-in > system, they can easily add their own custom git module that fits their > exact needs. Sure I suppose they could. However, I'm pretty sure that our generic module will suit their needs as soon as we've worked out the bugs. -- Thanks, Zac ^ permalink raw reply [flat|nested] 11+ messages in thread
* [gentoo-portage-dev] [PATCH] sync: always pass -q --unmerged to git-update-index 2016-11-03 4:57 ` Zac Medico 2016-11-03 6:17 ` Brian Dolbec @ 2016-11-03 19:22 ` Mike Gilbert 2016-11-03 19:29 ` Zac Medico 1 sibling, 1 reply; 11+ messages in thread From: Mike Gilbert @ 2016-11-03 19:22 UTC (permalink / raw To: gentoo-portage-dev 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 --- pym/portage/sync/modules/git/git.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/pym/portage/sync/modules/git/git.py b/pym/portage/sync/modules/git/git.py index dc94ec9..f288733 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)) -- 2.10.2 ^ permalink raw reply related [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q --unmerged to git-update-index 2016-11-03 19:22 ` [gentoo-portage-dev] [PATCH] sync: always pass -q --unmerged " Mike Gilbert @ 2016-11-03 19:29 ` Zac Medico 2016-11-03 19:59 ` Brian Dolbec 0 siblings, 1 reply; 11+ messages in thread From: Zac Medico @ 2016-11-03 19:29 UTC (permalink / raw To: gentoo-portage-dev On 11/03/2016 12:22 PM, Mike Gilbert wrote: > 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 > --- > pym/portage/sync/modules/git/git.py | 5 +---- > 1 file changed, 1 insertion(+), 4 deletions(-) > > diff --git a/pym/portage/sync/modules/git/git.py b/pym/portage/sync/modules/git/git.py > index dc94ec9..f288733 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)) > LGTM. -- Thanks, Zac ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q --unmerged to git-update-index 2016-11-03 19:29 ` Zac Medico @ 2016-11-03 19:59 ` Brian Dolbec 2016-11-03 20:06 ` Zac Medico 0 siblings, 1 reply; 11+ messages in thread From: Brian Dolbec @ 2016-11-03 19:59 UTC (permalink / raw To: gentoo-portage-dev On Thu, 3 Nov 2016 12:29:12 -0700 Zac Medico <zmedico@gentoo.org> wrote: > On 11/03/2016 12:22 PM, Mike Gilbert wrote: > > 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 > > --- > > pym/portage/sync/modules/git/git.py | 5 +---- > > 1 file changed, 1 insertion(+), 4 deletions(-) > > > > diff --git a/pym/portage/sync/modules/git/git.py > > b/pym/portage/sync/modules/git/git.py index dc94ec9..f288733 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)) > > LGTM. +1 LGTM too -- Brian Dolbec <dolsen> ^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [gentoo-portage-dev] [PATCH] sync: always pass -q --unmerged to git-update-index 2016-11-03 19:59 ` Brian Dolbec @ 2016-11-03 20:06 ` Zac Medico 0 siblings, 0 replies; 11+ messages in thread From: Zac Medico @ 2016-11-03 20:06 UTC (permalink / raw To: gentoo-portage-dev On 11/03/2016 12:59 PM, Brian Dolbec wrote: > On Thu, 3 Nov 2016 12:29:12 -0700 > Zac Medico <zmedico@gentoo.org> wrote: > >> On 11/03/2016 12:22 PM, Mike Gilbert wrote: >>> 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 >>> --- >>> pym/portage/sync/modules/git/git.py | 5 +---- >>> 1 file changed, 1 insertion(+), 4 deletions(-) >>> >>> diff --git a/pym/portage/sync/modules/git/git.py >>> b/pym/portage/sync/modules/git/git.py index dc94ec9..f288733 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)) >> >> LGTM. > > +1 LGTM too > Merged: https://gitweb.gentoo.org/proj/portage.git/commit/?id=d075422a8902617833ec945d94beb0bb334d44c9 -- Thanks, Zac ^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2016-11-03 20:06 UTC | newest] Thread overview: 11+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2016-11-02 21:09 [gentoo-portage-dev] [PATCH] sync: always pass -q to git-update-index Mike Gilbert 2016-11-03 0:17 ` Zac Medico 2016-11-03 4:57 ` Zac Medico 2016-11-03 6:17 ` Brian Dolbec 2016-11-03 16:10 ` Zac Medico 2016-11-03 17:03 ` Brian Dolbec 2016-11-03 17:27 ` Zac Medico 2016-11-03 19:22 ` [gentoo-portage-dev] [PATCH] sync: always pass -q --unmerged " Mike Gilbert 2016-11-03 19:29 ` Zac Medico 2016-11-03 19:59 ` Brian Dolbec 2016-11-03 20:06 ` Zac Medico
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox