How to get github pull request commits to be in the correct order
November 28, 2019
Problem
Sometimes after rebasing and force pushing, github will show commits in a different order from what you expect.
Solution
git rebase -i master --exec 'git commit --amend --date="$(date -R)"'
git push --force origin my-branch
If I remember correctly, some solutions to this problem will not fix the order in both the Conversation and Commits tabs, but this one does.
John Bachir's Code Blog