Git notes

Written early in the afternoon in English • Tags:

Some git workflows that I don’t do too often.

Keep a fork up to date

git add remote upstream https://...
git switch main
git fetch upstream
git pull upstream main
git push origin main

Remove a feature branch after merge

git branch -d mybranch
git push origin :mybranch

Refresh the list of remote branches

git remote update --prune

Add a comment