threads / patch / 5008

patch, 2 partsrebase: Fix the detection of fast-forwarding of the current branch to upstream.

Subject: [PATCH 1/2] rebase: Fix the detection of fast-forwarding of the current branch to upstream.

## tl;dr

One message between Jul 27, 2006 and Jul 27, 2006. Diffs are folded; open one to read it.

replies: 0people: 1as markdown or json

Robert Shearman· Jul 27, 2006, 09:32 UTC · lore

Previously, a rebasing operation with on a branch that is just tracking an upstream branch would output a confusing "Nothing to do" due to no patches being given to git-am.

The test brings the behaviour back into line with that of just before 
e646c9c8c0aa995eac284ea0a2117add19c4461c.
Signed-off-by: Robert Shearman <rob@codeweavers.com>
---
  git-rebase.sh |    2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)
Show changes to git-rebase.sh +1 −1
diff --git a/git-rebase.sh b/git-rebase.sh
index 29028dd..5554541 100755
--- a/git-rebase.sh
+++ b/git-rebase.sh
@@ -281,7 +281,7 @@ git-reset --hard "$onto"
 
 # If the $onto is a proper descendant of the tip of the branch, then
 # we just fast forwarded.
-if test "$mb" = "$onto"
+if test "$mb" = "$branch"
 then
 	echo >&2 "Fast-forwarded $branch to $newbase."
 	exit 0

← back to recent threads