Weird they don't talk of the `git commit --fixup=` command. And then `--autosquash` when rebasing.
fixup! Exact title of commit
We actually use that workflow during PR reviews on Github. That is, someone comments on a PR and the person who opened the PR will make a fixup commit with the appropriate title and reply to the comment stating that it was addressed and link the fixup commit by its abbreviated sha1 value.At the end of the PR review, the person who will merge the PR will run:
git fetch origin
git rebase -i --autosquash origin/master
git diff @{u}..
This basically updates the remote tracking branches (including origin/master), rebases the feature branch on top of the remote tracking branch for master, and then checks if any changes were introduced in the rebase process by running a diff against the remote tracking branch.If there is no diff or the diff only shows changes made on the upstream master branch since the feature branch was created, then they can run:
git push -f origin feature-branch-name
and then merge the PR.