Thread (71 messages) flat view 71 messages, 8 authors, 2016-06-15
STALE3725d

Revision v1 of 7 in this series.

Revisions (7)
  1. v1 current
  2. v3 [diff vs current]
  3. v4 [diff vs current]
  4. v5 [diff vs current]
  5. v6 [diff vs current]
  6. v7 [diff vs current]
  7. v8 [diff vs current]

[PATCH 0/4] Enhance git-rebases flexibiilty in handling empty commits

From: Neil Horman <nhorman@tuxdriver.com>
Date: 2016-06-15 22:53:26

Hey all-
	Based on your feedback from my earlier thread on this subject, I've come
up with this series as a first pass in enhancing git-rebases ability to handle
empty commits.  I'm not sure if its exactly what everyone wants, but I think its
a good start, and it works for what I need it to do here.

I started with adding a -keep-empty option to git-cherry-pick, which allows
non-fast forward commits that are empty to be cherry-pick without failing, and
requiring a separate git commit --allow-empty.

Building on that, I've added --keep-empty option to git-rebase.  For an
automatic rebase adding --keep-empty simply passes the --keep-empty flag along
to git cherry-pick so that the empty commits are preserved instead of discarded

for interactive rebases, I changed the default selection editor text somewhat.
By default, empty commits are allowed in this list.  With patch 4 here, empty
commits are commented out automatically, unless --keep-empty is selected (in
which case all commits are pick-ed).  The user sees additional text indicating
that empty commits are commented and if they wish to be kept, then they must be
uncommented.  The pick_one function then intellegently passes the --keep-empty
option allong to cherry-pick as needed.

Signed-off-by: Neil Horman <nhorman@tuxdriver.com>
CC: Jeff King <redacted>
CC: Phil Hord <redacted>
CC: Junio C Hamano <redacted>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help