author | Kevin Ballard <kevin@sb.org> | |
Thu, 4 Nov 2010 22:36:31 +0000 (15:36 -0700) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Tue, 9 Nov 2010 17:43:54 +0000 (09:43 -0800) | ||
commit | d3d7a421b1439a6f08dfbcd2e3327cbe90c93417 | |
tree | 15cde829d267f7d92b7005b13f8d80978219bfe1 | tree | snapshot |
parent | af77aee9cac51c2036e6019b4aebec2049f03e6b | commit | diff |
rebase: better rearranging of fixup!/squash! lines with --autosquash
The current behvaior of --autosquash can duplicate fixup!/squash! lines
if they match multiple commits, and it can also apply them to commits
that come after them in the todo list. Even more oddly, a commit that
looks like "fixup! fixup!" will match itself and be duplicated in the
todo list.
Change the todo list rearranging to mark all commits as used as soon
as they are emitted, and to avoid emitting a fixup/squash commit if the
commit has already been marked as used.
Signed-off-by: Kevin Ballard <kevin@sb.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
The current behvaior of --autosquash can duplicate fixup!/squash! lines
if they match multiple commits, and it can also apply them to commits
that come after them in the todo list. Even more oddly, a commit that
looks like "fixup! fixup!" will match itself and be duplicated in the
todo list.
Change the todo list rearranging to mark all commits as used as soon
as they are emitted, and to avoid emitting a fixup/squash commit if the
commit has already been marked as used.
Signed-off-by: Kevin Ballard <kevin@sb.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-rebase--interactive.sh | diff | blob | history | |
t/t3415-rebase-autosquash.sh | diff | blob | history |