emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: On the subject of Git, Bazaar, and the future of Emacs development


From: David Engster
Subject: Re: On the subject of Git, Bazaar, and the future of Emacs development
Date: Thu, 28 Mar 2013 10:07:29 +0100
User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3 (gnu/linux)

Stephen J. Turnbull writes:
> Multi-person, multi-branch workflows admit a nastier kind of geometry,
> which the Bazaar developers call "criss-cross merges" for an obvious
> reason:

Yes, I get 'criss-cross merge' warnings all the time.

To hopefully make clear what a "cross-project merge" implies, here's my
current setup for the CEDET merge:


       /--to-emacs  <-|   --------------------->
      /        ^      |         diff|patch
     |         |      |
     |         |      |
CEDET ----trunk|    <-|                         Emacs trunk
     |                |
     |                |
      \               |         diff|patch
       \--from-emacs -|   <--------------------


CEDET->Emacs: This is actually fairly easy. The 'to-emacs' branch is a
subset of Emacs trunk, containing only the files from CEDET upstream,
but generated from CEDET 'trunk'. This also handily tracks necessary
renames (for instance, EIEIO is located under lisp/emacs-lisp in Emacs,
but in CEDET it is in lisp/eieio). So in theory, I can just merge
'trunk' into 'to-emacs', generate a diff from this merge, and apply it
to Emacs trunk. In practice however, I get a conflict for every file
that was changed in 'trunk' but does not exist in 'to-emacs' (and there
are many such files). Unfortunately, bzr cannot automatically deal with
this (is git able to do that?). But it's a minor issue, since I can
easily script doing 'bzr --take-this resolve' on those files.

Emacs->CEDET: Now that's tedious. You have to first generate a list of
commits in Emacs trunk which changed files from CEDET. Then you try to
cherry-pick those commits into the 'from-emacs' branch. Doing this by
hand is a nightmare, so I've written a package for this
(cedet-emacs-merge.el in CEDET trunk). It generates this list, display
them nicely, lets me test the patches, show conflicts, generates commit
messages, and so on. Most importantly, it keeps track of things I have
applied or ignored and saves this state in the repository as a file
which I can load later.

When I've cherry-picked all the commits to 'from-emacs'. I also have to
merge it into 'to-emacs' before merging 'trunk', as I don't want things
in my diff for CEDET->Emacs which originated from Emacs in the first
place. I guess this is where the criss-crossing comes from.

Yep, it's messy. But I'm used to it now. The most time consuming thing
is fixing ChangeLogs (we don't have any in CEDET and generate them from
commit logs).

-David



reply via email to

[Prev in Thread] Current Thread [Next in Thread]