All technological notes.
| Command | Description |
|---|---|
git log |
Show commit history |
git commit -m "message" |
Create a new commit from staged changes |
git commit --amend -m "message" |
Modify the last commit |
git commit -a -m "message" |
automatically stages any tracked files that have been modified |
git reset --soft HEAD~1 |
Undo last commit, keep changes staged |
git reset --soft HEAD~1 |
Undo last commit, keep changes staged |