diff mercurial/merge.py @ 7768:5bf5fd1e2a74

merge: mark kept local files as readded on linear update (issue539)
author Matt Mackall <mpm@selenic.com>
date Sun, 15 Feb 2009 10:50:48 -0600
parents 0b2ee57dfdb1
children 89e05c02a4af
line wrap: on
line diff
--- a/mercurial/merge.py	Mon Feb 09 07:55:42 2009 -0600
+++ b/mercurial/merge.py	Sun Feb 15 10:50:48 2009 -0600
@@ -220,6 +220,7 @@
                       "use (c)hanged version or (d)elete?") % f,
                     _("[cd]"), _("c")) == _("d"):
                     act("prompt delete", "r", f)
+                act("prompt keep", "a", f)
             else:
                 act("other deleted", "r", f)
         else:
@@ -367,6 +368,9 @@
                 repo.dirstate.remove(f)
             else:
                 repo.dirstate.forget(f)
+        elif m == "a": # re-add
+            if not branchmerge:
+                repo.dirstate.add(f)
         elif m == "f": # forget
             repo.dirstate.forget(f)
         elif m == "e": # exec change