@@ -961,14 +961,13 @@ else
961961 revisions=$onto ...$orig_head
962962 shortrevisions=$shorthead
963963fi
964- git rev-list $merges_option --pretty=oneline --abbrev-commit \
965- --abbrev=7 --reverse --left-right --topo-order \
964+ git rev-list $merges_option --pretty=oneline --reverse --left-right --topo-order \
966965 $revisions ${restrict_revision+^$restrict_revision } | \
967966 sed -n " s/^>//p" |
968- while read -r shortsha1 rest
967+ while read -r sha1 rest
969968do
970969
971- if test -z " $keep_empty " && is_empty_commit $shortsha1 && ! is_merge_commit $shortsha1
970+ if test -z " $keep_empty " && is_empty_commit $sha1 && ! is_merge_commit $sha1
972971 then
973972 comment_out=" $comment_char "
974973 else
977976
978977 if test t ! = " $preserve_merges "
979978 then
980- printf ' %s\n' " ${comment_out} pick $shortsha1 $rest " >> " $todo "
979+ printf ' %s\n' " ${comment_out} pick $sha1 $rest " >> " $todo "
981980 else
982- sha1=$( git rev-parse $shortsha1 )
983981 if test -z " $rebase_root "
984982 then
985983 preserve=t
996994 if test f = " $preserve "
997995 then
998996 touch " $rewritten " /$sha1
999- printf ' %s\n' " ${comment_out} pick $shortsha1 $rest " >> " $todo "
997+ printf ' %s\n' " ${comment_out} pick $sha1 $rest " >> " $todo "
1000998 fi
1001999 fi
10021000done
@@ -1020,8 +1018,8 @@ then
10201018 # just the history of its first-parent for others that will
10211019 # be rebasing on top of it
10221020 git rev-list --parents -1 $rev | cut -d' ' -s -f2 > " $dropped " /$rev
1023- short =$( git rev-list -1 --abbrev-commit --abbrev=7 $rev )
1024- sane_grep -v " ^[a-z][a-z]* $short " < " $todo " > " ${todo} 2" ; mv " ${todo} 2" " $todo "
1021+ sha1 =$( git rev-list -1 $rev )
1022+ sane_grep -v " ^[a-z][a-z]* $sha1 " < " $todo " > " ${todo} 2" ; mv " ${todo} 2" " $todo "
10251023 rm " $rewritten " /$rev
10261024 fi
10271025 done
@@ -1054,6 +1052,7 @@ has_action "$todo" ||
10541052 return 2
10551053
10561054cp " $todo " " $todo " .backup
1055+ collapse_todo_ids
10571056git_sequence_editor " $todo " ||
10581057 die_abort " Could not execute editor"
10591058
0 commit comments