prune local remotes git fetch origin --prune delete local remote less branch git branch | grep -v "\* " | xargs git branch -d