It was reported via IRC that the exec lines are inserted in the wrong spots when using --rebase-merges. The reason is that we used a simple, incorrect implementation that happened to work as long as the generated todo list only contains pick, fixup and squash commands. Which is not the case with--rebase-merges. Fix this issue by using a correct, if longer and slightly more complex implementation instead. Johannes Schindelin (2): t3430: demonstrate what -r, --autosquash & --exec should do rebase --exec: make it work with --rebase-merges sequencer.c | 59 ++++++++++++++++++++++++++++++++-------- t/t3430-rebase-merges.sh | 17 ++++++++++++ 2 files changed, 65 insertions(+), 11 deletions(-) base-commit: 1d89318c48d233d52f1db230cf622935ac3c69fa Published-As: https://github.com/gitgitgadget/git/releases/tags/pr-13%2Fdscho%2Frebase-merges-and-exec-commands-v1 Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-13/dscho/rebase-merges-and-exec-commands-v1 Pull-Request: https://github.com/gitgitgadget/git/pull/13 -- gitgitgadget