git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alex Riesen <raa.lkml@gmail.com>
To: Jozef Babjak <jozef.babjak@gmail.com>
Cc: Git Mailing List <git@vger.kernel.org>
Subject: Re: Picking up multiple cherries at one go.
Date: Wed, 24 Mar 2010 12:52:22 +0100	[thread overview]
Message-ID: <81b0412b1003240452v57026439x7647535391e299fb@mail.gmail.com> (raw)
In-Reply-To: <ffef8f9a1003240236x34be6051ja8d013453d88d3a1@mail.gmail.com>

Please, don't strip gitml from cc. Your questions maybe interesting to
someone else.

On Wed, Mar 24, 2010 at 10:36, Jozef Babjak <jozef.babjak@gmail.com> wrote:
> Thanks for hint. I did not used interactive git commands ever; maybe I
> should try.
>
>> Try git rebase -i (interactive) next time. It does not exactly what your
>> script does, but ... You may like it.
>
>  ^-- Do you mean to make a copy of the multi_purpose_branch first and
> then to rebase interactively that new base onto master or any other
> ancestor branch and removing unwanted comits? The issue is that I
> usually want to keep only small portion of commits in newly created
> topic branch. It seems to be easier to mark somehow 5 commits I want
> instead of 95 commits I do not want.

You'll be amazed how easy it is (and how nothing it costs) to make a copy
of a branch: "git branch tmp". And you can rebase-interactive a portion
of the branch you're on: "git rebase -i HEAD~10". This will consider last
10 commits for cherry-picking. And even if you want to review all 100
commits, it maybe not that hard if you have a plain text file with subject
lines of the commits (and their sha1). You always can start a history
browser of your choice (gitk?) to help you with that.
At least that's how I do that since Johannes invented rebase-interactive.

      parent reply	other threads:[~2010-03-24 11:52 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-24  8:47 Picking up multiple cherries at one go Jozef Babjak
2010-03-24  9:21 ` Alex Riesen
     [not found]   ` <ffef8f9a1003240236x34be6051ja8d013453d88d3a1@mail.gmail.com>
2010-03-24 11:52     ` Alex Riesen [this message]

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=81b0412b1003240452v57026439x7647535391e299fb@mail.gmail.com \
    --to=raa.lkml@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=jozef.babjak@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;
as well as URLs for NNTP newsgroup(s).