Re: Managing multiple branches in git

From: Greg Stark <stark(at)enterprisedb(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Mark Mielke <mark(at)mark(dot)mielke(dot)cc>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Managing multiple branches in git
Date: 2009-06-03 09:57:55
Message-ID: 4136ffa0906030257i413209et647fb1c23f0f4119@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Jun 3, 2009 at 12:39 AM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> "David E. Wheeler" <david(at)kineticode(dot)com> writes:
>> Does that make sense?
>
> Maybe, but it still seems messy, brute force, and error-prone.
>
> I can't escape the feeling that we're missing something basic here.
> It's allegedly one of git's great strengths that it allows you to easily
> and quickly switch your attention among multiple development branches.

Well as long as the development branches are all "compatible" in the
sense that you don't nee to reconfigure and rebuild everything when
you switch then yes. Doing git-checkout to switch branches will work
fine for branches created to work on new code or review patches.

I really don't see what you mean by messy or brute force or
error-prone with regards to keeping a separate clone for each major
release. It's basically equivalent to having a CVS checkout for each
major release which you do now.

The main difference is that commit becomes a two step process --
commit to your repository, then push to the public repository. That's
three steps if you include the add but I suspect you're going to be
doing git-commit -a most of the time.

There's an advantage that you can commit several changes to your local
repo and push them all to the public repo together. That might be good
if you have, for example, a bug fix which requires an api change
elsewhere. You might want two separate commit messages and the ability
to merge one of them forward or back separately but not want to put
them in the public repo until both are available.

--
greg

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Gevik Babakhani 2009-06-03 10:04:52 Re: Question about STRICT
Previous Message Florian Weimer 2009-06-03 09:54:37 Re: [PATCH v2] Add bit operations util header