Hands-on task
Reorder commits with rebase
In /root/repo there are three commits in this order (oldest to newest): base, then hotfix, then feature. Logically the hotfix should have landed on top of the feature, not beneath it. Reorder the commits so the order becomes base, feature, hotfix — that is, hotfix becomes the newest commit and feature the one before it. Each commit touches its own file, so there won't be any conflicts; the number of commits stays three.
- git rebase
- interactive rebase
- commit order
- GIT_SEQUENCE_EDITOR
- git history