Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions 01_version_control/my_favorite_neat_little_git_trick_demo.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@
```

Usage: e.g. `git add -p ...` and then `git amend HEAD~5`. This would add the staged changes to the fifth last commit.
- Update an open PR without cluttering the history
- `git commit --amend --no-edit`
- `git push --force-with-lease origin <branch-name>`
- Perfect for fixing small nits or typos from code reviews. It updates the existing commit instead of adding a messy "fix typo" log.

## Tricks from Winter Term 2024/25

Expand Down