# Git commands for daily work
URL: https://wwadd.dev/moves/git-http/git-daily

Ninety percent of git use is this handful of commands. Learn `switch` and `restore` — they split the overloaded `checkout` into two clear jobs.


```bash
git switch -c feature/search      # new branch
git add -p                        # stage hunks interactively
git commit -m "Add search filter"
git push -u origin feature/search

git fetch origin
git rebase origin/main            # replay your work on top of main
git log --oneline --graph -20
```

## Related Moves
- [Undoing things in git](https://wwadd.dev/moves/git-http/git-undo)
- [REST basics](https://wwadd.dev/moves/git-http/rest-basics)

