Re: [PATCH 3/4] git-commit-am: Allow automatic rebasing to preserve empty commits
- From
Neil Horman <nhorman@tuxdriver.com>
- Date
- Mar 31, 2012, 13:01 UTC
- Message-ID
- <20120331130116.GC2409@neilslaptop.think-freely.org>
- In-Reply-To
- <7vd37tlsve.fsf@alter.siamese.dyndns.org>
On Fri, Mar 30, 2012 at 01:46:13PM -0700, Junio C Hamano wrote:
Show 6 quoted lines
> Neil Horman <nhorman@tuxdriver.com> writes: > > > Using the keep_empy environment variable, this change allows git-commit-am to > > Is it an environment variable? I thought not. >
Sorry, I use the term loosely. keep_empty is the script variable I use to track the keep-empty option. I can fix up the commit message on my repost.
Show 20 quoted lines
> > + # makes this easy > > + git cherry-pick --keep-empty "$revisions" && move_to_original_branch > > +else > > + git format-patch -k --stdout --full-index --ignore-if-in-upstream \ > > + --src-prefix=a/ --dst-prefix=b/ \ > > + --no-renames $root_flag "$revisions" | > > + git am $git_am_opt --rebasing --resolvemsg="$resolvemsg" && > > + move_to_original_branch > > +fi > > Factor out the "&& move_to_original_branch" at the end of then/else, like > this: > > if ... > then > ... > else > ... > fi && move_to_original_branch >
Will do, thanks! Neil