{"thread":{"id":"47236","subject":"v2.15.0: commits become falsely joined when rebasing (interactively)","startedAt":"2017-11-19T01:53:42Z","lastAt":"2017-11-19T01:53:42Z","messageCount":1,"participants":["Steffen Nurpmeso"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"332838","messageId":"20171119014508.OOpRb%steffen@sdaoden.eu","threadId":"47236","inReplyTo":null,"subject":"v2.15.0: commits become falsely joined when rebasing (interactively)","fromName":"Steffen Nurpmeso","fromEmail":"steffen@sdaoden.eu","sentAt":"2017-11-19T01:45:08Z","receivedAt":"2017-11-19T01:53:42Z","isPatch":false,"sender":{"key":"steffen@sdaoden.eu","avatar":"https://gravatar.com/avatar/d49e696effa4b8f04abdee3c3567a1638260b8fa05df4f389a373db04fc8a1b3?d=mp&s=160"},"body":"Hello again,\n\ni see an error with v2.15.0 that happened already back in early\nOctober (AlpineLinux [edge] pretty much up-to-date with newest git\nbut please don't ask exact version).  I failed to reproduce it\nback then, but now again, here is how.\n\n- It seems related to having a hook (pre-commit), and the \"reword\"\n  action.\n- Doing a rebase interactively to move (two) commits back from\n  HEAD downwards in a linear hierarchy, as in\n    * 306b5c7e (HEAD -> refs/heads/notpushed) [-] COMMIT 1\n    * 7e34d5fa [-] COMMIT 2\n  the above two to be moved down\n    * 65d216c3 (refs/remotes/origin/notpushed)...\n    ...\n    * 5ff5ef05 (refs/remotes/origin/next, refs/heads/next) [-]..\n  to end up stacked upon and as new [next]\n\n- COMMIT 2 is to be picked, but COMMIT 1 shall be \"r\"eworded.\n\nNow what happens is that COMMIT 2 is rebased ok, but instead of\nsimply opening the editor to allow rewording of the commit message\nof COMMIT 2 the pre-commit hook runs, and it has to complain in\nthis case (lines too long), but i \"commit -n\" that once\ni committed first.  Anyway git says\n\n  You can amend the commit now, with\n\n    git commit --amend\n\n  Once you are satisfied with your changes, run\n\n    git rebase --continue\n\nWhich i have not asked for!  More:\n\n  ?1[steffen@essex nail.git]$ git status\n  interactive rebase in progress; onto 6d437ab6\n  Last commands done (12 commands done):\n     pick 7e34d5fa [-] COMMIT 2\n     r 306b5c7e [-] COMMIT 1\n    (see more in file .git/rebase-merge/done)\n  Next commands to do (27 remaining commands):\n  ...\n    (use \"git rebase --edit-todo\" to view and edit)\n  You are currently rebasing branch 'notpushed' on '6d437ab6'.\n    (all conflicts fixed: run \"git rebase --continue\")\n\n  Changes to be committed:\n    (use \"git reset HEAD <file>...\" to unstage)\n\n          modified:   gen-okeys.h\n\n  Untracked files not listed (use -u option to show untracked files)\n\nSo far so good, but now:\n\n  ?0[steffen@essex nail.git]$ git rec\nalias: rebase --continue\n  [detached HEAD ca77a94a] COMMIT 1 with adjusted commit message\n   Date: Sun Nov 19 02:19:30 2017 +0100\n   9 files changed, 357 insertions(+), 339 deletions(-)\n  Successfully rebased and updated refs/heads/notpushed.\n\nUh!  It joined COMMIT 1 with COMMIT 2!\nThanks for git!\n\nCiao,\n\n--steffen\n|\n|Der Kragenbaer,                The moon bear,\n|der holt sich munter           he cheerfully and one by one\n|einen nach dem anderen runter  wa.ks himself off\n|(By Robert Gernhardt)\n"}]}