Re: Git's database structure
- From
Andreas Ericsson <ae@op5.se>
- Date
- Sep 4, 2007, 16:10 UTC
- Message-ID
- <46DD8387.3040801@op5.se>
- In-Reply-To
- <20070904160726.GA17509@glandium.org>
Mike Hommey wrote:
Show 19 quoted lines
> On Tue, Sep 04, 2007 at 05:55:16PM +0200, Andreas Ericsson <ae@op5.se> wrote: >> Each root tree can only ever belong to a single commit, unless you >> intentionally force git to make completely empty commits. git >> won't complain about this, so long as you don't make two in the >> same second, because it relies more heavily on the DAG than on >> developer sanity. > > Actually, you don't need to be insane to have multiple commits pointing > at the same root tree. It is actually very easy: > - git clone > - do some stuff on your master branch and commit > - send your changes upstream > - upstream applies as is > - git pull > > You now have everything merged, and the last commit on your master branch, > while being a different commit object due to its parenting, has the same > root tree as the tip of the remote branch. >
That explains why it felt so awkward writing that sentence. :) Thanks for correcting me. Even so, one more M<->M relation-ship certainly speaks for rather than against the current model.
-- Andreas Ericsson andreas.ericsson@op5.se OP5 AB www.op5.se Tel: +46 8-230225 Fax: +46 8-230231