Como excluir todas as filiais no Git Local

git branch | grep -v "main" | xargs git branch -D
Healthy Hyena