summaryrefslogtreecommitdiff
path: root/git-rebase--interactive.sh
diff options
context:
space:
mode:
authorJohannes Schindelin <Johannes.Schindelin@gmx.de>2007-08-01 22:31:03 (GMT)
committerJunio C Hamano <gitster@pobox.com>2007-08-02 01:17:56 (GMT)
commitc9e6589288b09f4e631c7f12f0f9a77c29851632 (patch)
tree1c4d1aa4483d4e619b2e0eea7c38660b938fbce9 /git-rebase--interactive.sh
parent434e6ef89d73dcc812b3a44dfaff0ca8204a206e (diff)
downloadgit-c9e6589288b09f4e631c7f12f0f9a77c29851632.zip
git-c9e6589288b09f4e631c7f12f0f9a77c29851632.tar.gz
git-c9e6589288b09f4e631c7f12f0f9a77c29851632.tar.bz2
rebase -i: fix for optional [branch] parameter
When calling "git rebase -i <upstream> <branch>", git should switch to <branch> first. This worked before, but I broke it by my "Shut git rebase -i up" patch. Fix that, and add a test to make sure that it does not break again. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Acked-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-rebase--interactive.sh')
-rwxr-xr-xgit-rebase--interactive.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh
index d3addd4..bdec462 100755
--- a/git-rebase--interactive.sh
+++ b/git-rebase--interactive.sh
@@ -405,6 +405,7 @@ do
require_clean_work_tree
+ mkdir "$DOTEST" || die "Could not create temporary $DOTEST"
if test ! -z "$2"
then
output git show-ref --verify --quiet "refs/heads/$2" ||
@@ -418,7 +419,6 @@ do
test -z "$ONTO" && ONTO=$UPSTREAM
- mkdir "$DOTEST" || die "Could not create temporary $DOTEST"
: > "$DOTEST"/interactive || die "Could not mark as interactive"
git symbolic-ref HEAD > "$DOTEST"/head-name ||
die "Could not get HEAD"