Mercurial > evolve
changeset 4583:4fcf9a71befc
evolve: show a status message when merging leads to public cset
I think it would be fine to tell the user that merging the two divergent
csets while resolving public divergence resulted into the public cset
itself.
If you think we don't need to tell the user, then we can include this
in debug-mode for debugging purposes at least.
author | Sushil khanchi <sushilkhanchi97@gmail.com> |
---|---|
date | Wed, 17 Apr 2019 21:16:17 +0530 |
parents | 985d4c1336f6 |
children | fd8dada76730 |
files | hgext3rd/evolve/evolvecmd.py tests/test-evolve-public-content-divergent-corner-cases.t tests/test-evolve-public-content-divergent-discard.t |
diffstat | 3 files changed, 11 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/hgext3rd/evolve/evolvecmd.py Wed Apr 24 20:32:01 2019 +0200 +++ b/hgext3rd/evolve/evolvecmd.py Wed Apr 17 21:16:17 2019 +0530 @@ -544,6 +544,13 @@ return (res, newnode) if newnode == publicdiv.node(): # case 2) + pubstr = str(publicdiv) + othstr = str(other) + msg = _('content divergence resolution between %s ' + '(public) and %s has same content as %s, ' + 'discarding %s\n') + msg %= (pubstr, othstr, pubstr, othstr) + repo.ui.status(msg) return (res, newnode) # case 1) prec = publicdiv
--- a/tests/test-evolve-public-content-divergent-corner-cases.t Wed Apr 24 20:32:01 2019 +0200 +++ b/tests/test-evolve-public-content-divergent-corner-cases.t Wed Apr 17 21:16:17 2019 +0530 @@ -642,6 +642,7 @@ updating to "local" side of the conflict: c7d2d47c7240 merging "other" content-divergent changeset '0773642cfa95' 0 files updated, 0 files merged, 0 files removed, 0 files unresolved + content divergence resolution between c7d2d47c7240 (public) and 0773642cfa95 has same content as c7d2d47c7240, discarding 0773642cfa95 1 new orphan changesets merge:[8] c_F with: [10] c_F @@ -650,6 +651,7 @@ updating to "local" side of the conflict: a52ac76b45f5 merging "other" content-divergent changeset '6a87ed4aa317' 0 files updated, 0 files merged, 0 files removed, 0 files unresolved + content divergence resolution between a52ac76b45f5 (public) and 6a87ed4aa317 has same content as a52ac76b45f5, discarding 6a87ed4aa317 $ hg sum parent: 8:a52ac76b45f5 tip c_F
--- a/tests/test-evolve-public-content-divergent-discard.t Wed Apr 24 20:32:01 2019 +0200 +++ b/tests/test-evolve-public-content-divergent-discard.t Wed Apr 17 21:16:17 2019 +0530 @@ -93,6 +93,7 @@ merging "other" content-divergent changeset '90522bccf499' 0 files updated, 0 files merged, 0 files removed, 0 files unresolved content-divergent changesets differ by descriptions only, discarding 90522bccf499 + content divergence resolution between f7c1071f1e7c (public) and 90522bccf499 has same content as f7c1071f1e7c, discarding 90522bccf499 $ hg evolve -l @@ -186,6 +187,7 @@ merging "other" content-divergent changeset 'ae3429430ef1' 0 files updated, 0 files merged, 0 files removed, 0 files unresolved content-divergent changesets differ by descriptions only, discarding ae3429430ef1 + content divergence resolution between e800202333a4 (public) and ae3429430ef1 has same content as e800202333a4, discarding ae3429430ef1 $ hg evolve -l