From: Junio C Hamano Date: Sat, 3 Apr 2010 19:28:38 +0000 (-0700) Subject: Merge branch 'do/rebase-i-arbitrary' X-Git-Tag: v1.7.1-rc0~25 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=df9930c129d4cfe4d39e5e4688a6a55a2bca0050;p=git.git Merge branch 'do/rebase-i-arbitrary' * do/rebase-i-arbitrary: rebase--interactive: don't require what's rebased to be a branch Conflicts: t/t3404-rebase-interactive.sh --- df9930c129d4cfe4d39e5e4688a6a55a2bca0050 diff --cc t/t3404-rebase-interactive.sh index 19668c2c9,05708c246..b0b43c6d3 --- a/t/t3404-rebase-interactive.sh +++ b/t/t3404-rebase-interactive.sh @@@ -553,28 -553,13 +553,37 @@@ test_expect_success 'reword' git show HEAD~2 | grep "C changed" ' +test_expect_success 'rebase -i can copy notes' ' + git config notes.rewrite.rebase true && + git config notes.rewriteRef "refs/notes/*" && + test_commit n1 && + test_commit n2 && + test_commit n3 && + git notes add -m"a note" n3 && + git rebase --onto n1 n2 && + test "a note" = "$(git notes show HEAD)" +' + +cat >expect < output && + test_cmp expect output +' + + test_expect_success 'rebase while detaching HEAD' ' + git symbolic-ref HEAD && + grandparent=$(git rev-parse HEAD~2) && + test_tick && + FAKE_LINES="2 1" git rebase -i HEAD~2 HEAD^0 && + test $grandparent = $(git rev-parse HEAD~2) && + test_must_fail git symbolic-ref HEAD + ' + test_done