summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 41f556b)
raw | patch | inline | side by side (parent: 41f556b)
author | Junio C Hamano <gitster@pobox.com> | |
Tue, 6 Jul 2010 06:08:36 +0000 (23:08 -0700) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Tue, 6 Jul 2010 06:23:37 +0000 (23:23 -0700) |
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-rebase--interactive.sh | patch | blob | history | |
t/t3404-rebase-interactive.sh | patch | blob | history |
index ed57552b7ece38a235043a7aa03a0a413fc41c5f..31e68603f4e8124fd67f42c8aae6033a792892cb 100755 (executable)
do_next () {
rm -f "$MSG" "$AUTHOR_SCRIPT" "$AMEND" || exit
- read command sha1 rest < "$TODO"
+ read -r command sha1 rest < "$TODO"
case "$command" in
'#'*|''|noop)
mark_action_done
# skip picking commits whose parents are unchanged
skip_unnecessary_picks () {
fd=3
- while read command sha1 rest
+ while read -r command sha1 rest
do
# fd=3 means we skip the command
case "$fd,$command,$(git rev-parse --verify --quiet $sha1^)" in
test -s "$1.sq" || return
used=
- while read pick sha1 message
+ while read -r pick sha1 message
do
case " $used" in
*" $sha1 "*) continue ;;
esac
echo "$pick $sha1 $message"
- while read squash action msg
+ while read -r squash action msg
do
case "$message" in
"$msg"*)
--abbrev=7 --reverse --left-right --topo-order \
$REVISIONS | \
sed -n "s/^>//p" |
- while read shortsha1 rest
+ while read -r shortsha1 rest
do
if test t != "$PRESERVE_MERGES"
then
index ee9a1b25e6a35adcb2350068d3b63b50bc9c24b3..47ca88fc5231a5e0689b43a35eb660285a73190d 100755 (executable)
test_cmp empty out
'
+test_expect_success 'set up commits with funny messages' '
+ git checkout -b funny A &&
+ echo >>file1 &&
+ test_tick &&
+ git commit -a -m "end with slash\\" &&
+ echo >>file1 &&
+ test_tick &&
+ git commit -a -m "another commit"
+'
+
+test_expect_success 'rebase-i history with funny messages' '
+ git rev-list A..funny >expect &&
+ test_tick &&
+ FAKE_LINES="1 2" git rebase -i A &&
+ git rev-list A.. >actual &&
+ test_cmp expect actual
+'
+
test_done