evolve: take out logic to complete phase-divergence in separate fn
authorPulkit Goyal <7895pulkit@gmail.com>
Sun, 29 Apr 2018 18:13:29 +0530
changeset 3735 bdf7fb6af7b8
parent 3734 aae54e80c95c
child 3736 4b8c63d14f18
evolve: take out logic to complete phase-divergence in separate fn This patch takes out the logic to complete the content-divergence resolution to it's own separate function so that we can reuse it in case of interrupted resolution.
hgext3rd/evolve/evolvecmd.py
--- a/hgext3rd/evolve/evolvecmd.py	Sun Apr 29 17:54:01 2018 +0530
+++ b/hgext3rd/evolve/evolvecmd.py	Sun Apr 29 18:13:29 2018 +0530
@@ -426,6 +426,11 @@
 /!\ * hg ci -m "same message as the amended changeset" => new cset Y
 /!\ * hg prune -n Y W Z
 """)
+
+    return _completecontentdivergence(ui, repo, progresscb, divergent, other)
+
+def _completecontentdivergence(ui, repo, progresscb, divergent, other):
+    """completes the content-divergence resolution"""
     if progresscb:
         progresscb()
     emtpycommitallowed = repo.ui.backupconfig('ui', 'allowemptycommit')