dummy merge (two branches) for dummies
Matt Mackall
mpm at selenic.com
Thu Aug 18 01:39:34 UTC 2016
On Wed, 2016-08-17 at 21:28 +0000, Uwe Brauer wrote:
> Hello
>
> This drives me crazy.
> My repo has two branches.
> The output of log -G is for example
> (I had to abounded the merge maybe this is the reason why both seem to
> be active.
>
> @ changeset: 60:9f51f0a1bc8b
> >
> > branch: foo
> > tag: tip
> > parent: 53:c14490f0ccdf
> > user: Uwe Brauer <oub at mat.ucm.es>
> > date: Wed Aug 17 21:04:25 2016 +0000
> > summary: Foos changes from 17.8
> >
> > @ changeset: 59:c95d1d5985e7
> > >
> > > branch: uwe
> > > user: Uwe Brauer <oub at mat.ucm.es>
> > > date: Tue Aug 16 16:08:39 2016 +0000
> > > summary: Added tag vs-4 for changeset fa9ae2bfc4bc
> > >
> So I just want to merge *all* changes (of the tip) from the foo branch into
> the
> branch uwe.
>
> What is the easiest way to do that?
>
> Is
> hg --config ui.merge=internal:foo merge
It's not the magic.
The magic is to do the merge followed by a full revert.
hg update A <- go to the branch you want to keep
hg merge B <- merge in the branch you want to discard
hg revert --all -r A <- make working copy look like a (the magic)
hg diff <- confirm that nothing's changed relative to p1
hg commit
Now, in the course of doing the merge command, you may encounter some
challenging merges that are pointless to spend any time on, since you're going
to throw the results away. You can make those merges instant by specifying that
Mercurial do something simple:
hg merge --tool internal:local
--
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial
mailing list