kb:scc:git:advanced
Table of Contents
14 Advanced Usage
Remove Accidental Commit (lose changes)
This doesn't work if you've already pushed the commit to a remote.
Lose changes
# remove the last commit from the current branch git reset HEAD~ --hard
keep changes
# remove the last commit from the current branch git reset HEAD~ --soft
kb/scc/git/advanced.txt · Last modified: 2024/01/09 10:04 by joerg.hampel