From: Björn Steinbrink Date: Wed, 23 Jul 2008 14:06:08 GMT Subject: Re: q: faster way to integrate/merge lots of topic branches? Message-ID: <20080723140608.GC11679@atjola.homenet> In-Reply-To: <20080723130518.GA17462@elte.hu> On 2008.07.23 15:05:18 +0200, Ingo Molnar wrote: > > I've got the following, possibly stupid question: is there a way to > merge a healthy number of topic branches into the master branch in a > quicker way, when most of the branches are already merged up? > > Right now i've got something like this scripted up: > > for B in $(git-branch | cut -c3- ); do git-merge $B; done Not yet in any release (AFAICT), but with git.git master, you could use: for B in $(git branch --no-merged); do git-merge $B; done Or with earlier versions, this should work, but it's a lot slower: for B in $(git branch | cut -c3- ); do [[ -n "$(git rev-list -1 HEAD..$B)" ]] && git merge $B; done Björn