git fetch origin > /dev/null; git checkout origin/main; for branch in $(git branch -a --merged | grep remotes/origin | grep -v main | grep -v 'no branch'| sed -e 's/\s*remotes\///'); do echo "${branch:7}"; done; git checkout main
git fetch origin > /dev/null; git checkout origin/main; for branch in $(git branch -a --merged | grep remotes/origin | grep -v main | grep -v 'no branch'| sed -e 's/\s*remotes\///'); do git push origin :${branch:7}"; done; git checkout main