Script for automated pull+merge
Greg Ward
greg at gerg.ca
Fri Apr 9 15:58:40 CDT 2010
On Fri, Apr 9, 2010 at 4:19 PM, Benjamin Pollack <benjamin at bitquabit.com> wrote:
> When Kiln aborted on merge failure, developers soon learned not to trust the automatic pull, since they couldn't be sure they'd actually get all of the upstream changesets. They ended up just always pulling manually from upstream.
Huh. Did you use the algorithm I sketched or something different?
After talking to a co-worker, I've tweaked the planned algorithm a
bit:
pull from R1 to R2
if any branches in R2 have multiple heads:
get a working copy of R2 (clone? share? not sure yet)
for each branch with multiple heads:
update to branch head with lower revnum
merge with internal:fail
if merge failed:
warn: file-level merges needed on $branch #
instead of aborting
else:
commit "merge R1 to R2"
push to the real R2 (assuming we cloned rather than shared)
email warnings to responsible address
In other words, we've already jumped from your initial implementation
(abort on merge failure) to your second implementation (push multiple
heads to R2 and leave it up to a human to merge). And it sounds like
your experience with version #2 was worse than version #1. Hmmmmm.
Greg
More information about the Mercurial
mailing list