Mercurial > evolve
changeset 5553:355a7c91ce9a
evolve: rename haspubdiv to haspublicdiv for more clarity
author | Sushil khanchi <sushilkhanchi97@gmail.com> |
---|---|
date | Wed, 12 Aug 2020 17:21:05 +0530 |
parents | 4c328eb7196e |
children | c61a31489da0 |
files | hgext3rd/evolve/evolvecmd.py |
diffstat | 1 files changed, 12 insertions(+), 11 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext3rd/evolve/evolvecmd.py Fri Aug 07 00:25:13 2020 +0530 +++ b/hgext3rd/evolve/evolvecmd.py Wed Aug 12 17:21:05 2020 +0530 @@ -312,10 +312,11 @@ evolvestate[b'divergent'] = div.node() evolvestate[b'other-divergent'] = other.node() return div, other - # haspubdiv: to keep track if we are solving public content-divergence - haspubdiv = False + + # haspublicdiv: to keep track if we are solving public content-divergence + haspublicdiv = False if not (divergent.mutable() and other.mutable()): - haspubdiv = True + haspublicdiv = True # for simplicity, we keep public one to local side while merging # (as divergent is kept at local side, pinning public -> divergent) if divergent.mutable(): @@ -404,7 +405,7 @@ pass if otheronly: relocatereq = True - if not haspubdiv: + if not haspublicdiv: # can't swap when public divergence, as public can't move divergent, other = swapnodes(divergent, other) resolutionparent = repo[succsotherp1].node() @@ -427,7 +428,7 @@ # # Otherwise, we are going to rebase the "behind" branch up to the new # brancmap level. - if not haspubdiv: + if not haspublicdiv: divergent, other = swapnodes(divergent, other) resolutionparent = divergent.p1().node() else: @@ -552,8 +553,8 @@ evolvestate) res, newnode = _completecontentdivergent(ui, repo, progresscb, divergent, other, base, evolvestate) - haspubdiv = not (divergent.mutable() and other.mutable()) - if not haspubdiv: + haspublicdiv = not (divergent.mutable() and other.mutable()) + if not haspublicdiv: return (res, newnode) else: publicdiv = repo[evolvestate[b'public-divergent']] @@ -623,9 +624,9 @@ resparent = evolvestate[b'resolutionparent'] # whether we are solving public divergence - haspubdiv = False + haspublicdiv = False if evolvestate.get(b'public-divergent'): - haspubdiv = True + haspublicdiv = True publicnode = evolvestate[b'public-divergent'] publicdiv = repo[publicnode] othernode = evolvestate[b'other-divergent'] @@ -681,14 +682,14 @@ newnode = repo.commit(text=desc, user=user, date=date, extra=extra) new = repo[newnode] hg.updaterepo(repo, new.rev(), False) - if haspubdiv and publicdiv == divergent: + if haspublicdiv and publicdiv == divergent: bypassphase(repo, (divergent, new), operation=b'evolve') else: obsolete.createmarkers(repo, [(divergent, (new,))], operation=b'evolve') # creating markers and moving phases post-resolution - if haspubdiv and publicdiv == other: + if haspublicdiv and publicdiv == other: bypassphase(repo, (other, new), operation=b'evolve') else: obsolete.createmarkers(repo, [(other, (new,))], operation=b'evolve')