# HG changeset patch # User Paul Eggert # Date 1295302165 28800 # Node ID 256406bc04fe46858119c21c2ca2c7a32e27212c # Parent 7e12e8b5864c4e7301b4a1398509018b3ba3cf5a# Parent 7e5855ddf3f2395308f34d0d891d3325c51f450d Merge from mainline. diff -r 7e12e8b5864c -r 256406bc04fe admin/ChangeLog --- a/admin/ChangeLog Mon Jan 17 11:47:38 2011 -0800 +++ b/admin/ChangeLog Mon Jan 17 14:09:25 2011 -0800 @@ -1,3 +1,8 @@ +2011-01-17 Stefan Monnier + + * bzrmerge.el (bzrmerge-apply): Warn the user when the tree might be in + an inconsistent state. + 2011-01-17 Paul Eggert Update copyright notes to match recent gnulib-related changes. diff -r 7e12e8b5864c -r 256406bc04fe admin/bzrmerge.el --- a/admin/bzrmerge.el Mon Jan 17 11:47:38 2011 -0800 +++ b/admin/bzrmerge.el Mon Jan 17 14:09:25 2011 -0800 @@ -218,6 +218,7 @@ (setq bzrmerge-already-done nil) (let ((merge (car missing)) (skip (cdr missing)) + (unsafe nil) beg end) (when (or merge skip) (cond @@ -249,6 +250,7 @@ "--force" "-r" (format "%s..%s" beg end) from) ;; The merge did not update the metadata, so force the next time ;; around to update it (as a "skip"). + (setq unsafe t) (push end skip)) (pop-to-buffer (current-buffer)) (sit-for 1) @@ -271,6 +273,15 @@ (when conflicted (setq bzrmerge-already-done (list (cons merge skip) from missing)) + (if unsafe + ;; FIXME: Obviously, we'd rather make it right rather + ;; than output such a warning. But I don't know how to add + ;; the metadata to bzr's since the technique used in + ;; bzrmerge-add-metadata does not work when there + ;; are conflicts. + (display-warning 'bzrmerge "Resolve conflicts manually. +¡BEWARE! Important metadata is kept in this Emacs session! +Do not commit without re-running `M-x bzrmerge' first!"))) (error "Resolve conflicts manually"))))) (cons merge skip)))))