Hongyi Zhao <hongyi.zhao@xxxxxxxxx> writes: > Because the commit I want to revert is done a long time ago, which is > not the parent of the commit I'm currently on, so I can't use the `~1` > which indicates that I want to go back one commit from my current > position. You *can* use HEAD~1. After the git revert, a new commit has been created, and so HEAD~1 refers to the state of things before running git revert.