How do I reset my all local branches, one time to be just like the branches in the remote repository?
I have 42 branches in my local repository, but I have just 21 branches in my remote repository. I don't need the other branches, I just need the 21 branches (with same name in local and remote).
I know
git fetch origin
git reset --hard origin/master
but I want all 21 branches to together reset hard to the state in origin, and all other branches deleted that are not in origin.