git reset --soft "HEAD@{1}"
git commit -m "commit message"
HEAD@{1}
means "find where HEAD
was before the current commit". You can verify it's really the previous (unmodified) commit using git reflog
and git show "HEAD@{1}"
.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…