Git development
 help / color / mirror / Atom feed
From: "Björn Steinbrink" <B.Steinbrink@gmx.de>
To: David <wizzardx@gmail.com>
Cc: Wincent Colaiuta <win@wincent.com>, git@vger.kernel.org
Subject: Re: User's mailing list? And multiple cherry pick
Date: Wed, 4 Jun 2008 20:09:31 +0200	[thread overview]
Message-ID: <20080604180931.GA31188@atjola.homenet> (raw)
In-Reply-To: <18c1e6480806040302k74156d47p4e878fef62d21b87@mail.gmail.com>

On 2008.06.04 12:02:13 +0200, David wrote:
> On Wed, Jun 4, 2008 at 11:39 AM, Wincent Colaiuta <win@wincent.com> wrote:
> > El 4/6/2008, a las 10:30, David escribió:
> >
> >> Thanks :-) This still isn't what I had in mind (see my earlier post
> >> with examples), but I realise now, thanks to your post, that I can
> >> probably do it like this:
> 
> [snip]
> 
> >
> > Sounds like it would definitely work but it also sounds like a lot of
> > repetitive "busy work"[1] which could be avoided by using finer-grained
> > topic branches in the first place.
> >
> 
> It isn't always easy to fix the problems in master (that you're seeing
> in topic) by changing back to master and making another topic. Maybe
> you can only (easily) find & detect the problems in master because of
> other changes in topic (eg: WIP unit tests) that you aren't ready to
> merge yet.
> 
> So you would probably have to jump back and forth between your topic,
> and your new 'fix problems in master' branch a lot to track down the
> issues and get the fixes into master. This sounds like a lot more
> 'busy work' than simply cherry-picking (multiple) those fixes out of
> your topic branch into master, and then rebasing your topic branch :-)

The unit tests example is a pretty good use-case for rebase --onto.
Simply start your new topic on top of the WIP topic, you don't always
have to branch from master. Then you have the all the code around. Fix
the bug, and finally rebase your new topic onto master.

git checkout -b bug_fix_branch wip_branch
# work work work, commit commit commit
git rebase --onto master wip_branch bug_fix_branch

Eventually, you'll have to add stuff to your wip_branch while doing the
bug_fix, but that's relatively straight forward.

git checkout wip_branch
# work work work, commit commit commit
git rebase wip_branch bug_fix_branch

And then you can continue to work on the bug fix branch and at some
point end up at the rebase --onto from above.

Of course for stronger dependencies between wip_branch and
bug_fix_branch, that's not possible, but then you most likely wouldn't
want to cherry-pick the bug fix stuff into master anyway.

Björn

  parent reply	other threads:[~2008-06-04 18:10 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-04  6:55 User's mailing list? And multiple cherry pick David
2008-06-04  6:58 ` Junio C Hamano
2008-06-04  7:13   ` David
2008-06-04  8:05     ` Jakub Narebski
2008-06-04  8:23       ` Johan Herland
2008-06-04  8:30       ` David
2008-06-04  9:39         ` Wincent Colaiuta
2008-06-04 10:02           ` David
2008-06-04 11:02             ` Wincent Colaiuta
2008-06-04 11:09             ` Jakub Narebski
2008-06-04 18:09             ` Björn Steinbrink [this message]
2008-06-04  8:16     ` Johan Herland
2008-06-04  7:39 ` Jakub Narebski
2008-06-04  8:11   ` David
2008-06-04  8:50     ` Jakub Narebski
2008-06-04  9:37       ` David
2008-06-04  9:47         ` Jakub Narebski
2008-06-04 11:36     ` Theodore Tso
2008-06-04 10:38   ` Karl Hasselström
2008-06-04 11:10     ` Miklos Vajna
2008-06-04  8:00 ` Stephan Beyer
2008-06-04  8:20   ` David

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20080604180931.GA31188@atjola.homenet \
    --to=b.steinbrink@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=win@wincent.com \
    --cc=wizzardx@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox