So that all the tests pass.

Signed-off-by: Felipe Contreras <>
--- | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/ b/
index ca78b1b..c3a2ac9 100644
--- a/
+++ b/
@@ -23,11 +23,26 @@ test -n "$rebase_root" && root_flag=--root
 mkdir "$state_dir" || die "Could not create temporary $state_dir"
 : > "$state_dir"/cherry || die "Could not mark as cherry"
+if test -n "$rebase_root"
+       revisions="$onto...$orig_head"
+       revisions="$upstream...$orig_head"
 # we have to do this the hard way.  git format-patch completely squashes
 # empty commits and even if it didn't the format doesn't really lend
 # itself well to recording empty patches.  fortunately, cherry-pick
 # makes this easy
-git cherry-pick --allow-empty "$revisions"
+if test -n "$keep_empty"
+       extra="--allow-empty"
+       extra="--skip-empty --cherry-pick"
+test -n "$GIT_QUIET" && extra="$extra -q"
+test -z "$force_rebase" && extra="$extra --ff"
+git cherry-pick --no-merges --right-only --topo-order --do-walk --copy-notes 
$extra "$revisions"
 if test 0 != $ret

To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to
More majordomo info at

Reply via email to