From: Michael Radziej Date: Fri, 07 Nov 2008 10:46:30 GMT Subject: Re: multiple-commit cherry-pick? Message-ID: <20081107104630.GB12424@noris.de> In-Reply-To: <7vskq4gmf5.fsf@gitster.siamese.dyndns.org> On Thu, Nov 06, Junio C Hamano wrote: > Or "git show --pretty=email $commit1 $commit2" ... piped to "am"? Or make git show write shell commands. I often have commits that later need to be cherry-picked into other branches. For these, I use a commit message that starts with the name of the branch, like "implement-foo: make foo barfy". Later when I want to do the cherry-picking, I use this: git log t/whatever..master --reverse --pretty=tformat:'git cherry-pick %h # %s' | sed 's/^\([^:]*\) \([^:]*\):/git checkout \2 \&\& \1/' giving me output like: git checkout implement-foo && git cherry-pick 90ce727 # make foo barfy git checkout ... ... and I'm ready for cut'n'paste. Michael -- noris network AG - Deutschherrnstraße 15-19 - D-90429 Nürnberg - Tel +49-911-9352-0 - Fax +49-911-9352-100 http://www.noris.de - The IT-Outsourcing Company Vorstand: Ingo Kraupa (Vorsitzender), Joachim Astel, Hansjochen Klenk - Vorsitzender des Aufsichtsrats: Stefan Schnabel - AG Nürnberg HRB 17689