diff options
author | Junio C Hamano <gitster@pobox.com> | 2021-03-26 14:59:03 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-03-26 14:59:03 -0700 |
commit | ce4296cf2b6f66d8717e8c3237c9b4be42fb2a1b (patch) | |
tree | 628a8617606cf211328a8595f45947d92dfc96fb /t/t3437 | |
parent | Merge branch 'js/http-pki-credential-store' (diff) | |
parent | doc/git-rebase: add documentation for fixup [-C|-c] options (diff) | |
download | tgif-ce4296cf2b6f66d8717e8c3237c9b4be42fb2a1b.tar.xz |
Merge branch 'cm/rebase-i'
"rebase -i" is getting cleaned up and also enhanced.
* cm/rebase-i:
doc/git-rebase: add documentation for fixup [-C|-c] options
rebase -i: teach --autosquash to work with amend!
t3437: test script for fixup [-C|-c] options in interactive rebase
rebase -i: add fixup [-C | -c] command
sequencer: use const variable for commit message comments
sequencer: pass todo_item to do_pick_commit()
rebase -i: comment out squash!/fixup! subjects from squash message
sequencer: factor out code to append squash message
rebase -i: only write fixup-message when it's needed
Diffstat (limited to 't/t3437')
-rw-r--r-- | t/t3437/expected-combined-message | 21 | ||||
-rw-r--r-- | t/t3437/expected-squash-message | 51 |
2 files changed, 72 insertions, 0 deletions
diff --git a/t/t3437/expected-combined-message b/t/t3437/expected-combined-message new file mode 100644 index 0000000000..a26cfb2fa9 --- /dev/null +++ b/t/t3437/expected-combined-message @@ -0,0 +1,21 @@ +# This is a combination of 4 commits. +# This is the 1st commit message: + +B + +# This is the commit message #2: + +# amend! B + +new subject + +new +body + +# The commit message #3 will be skipped: + +# A2 + +# This is the commit message #4: + +A3 diff --git a/t/t3437/expected-squash-message b/t/t3437/expected-squash-message new file mode 100644 index 0000000000..ab2434f90e --- /dev/null +++ b/t/t3437/expected-squash-message @@ -0,0 +1,51 @@ +# This is a combination of 6 commits. +# The 1st commit message will be skipped: + +# B +# +# Signed-off-by: Rebase Committer <rebase.committer@example.com> + +# The commit message #2 will be skipped: + +# fixup! B + +# The commit message #3 will be skipped: + +# amend! B +# +# B +# +# edited 1 +# +# Signed-off-by: Rebase Committer <rebase.committer@example.com> + +# This is the commit message #4: + +# amend! amend! B + +B + +edited 1 + +edited 2 + +Signed-off-by: Rebase Committer <rebase.committer@example.com> + +# This is the commit message #5: + +# squash! amend! amend! B + +edited squash + +# This is the commit message #6: + +# amend! amend! amend! B + +B + +edited 1 + +edited 2 + +edited 3 +squashed |