Cheatsheet Pages / Git Cheatsheet
How to delete a Git branch locally and on the remote
A feature is merged and its branches are cluttering your local and remote lists.
git branch -d feature/login # safe delete (fails if unmerged)
git branch -D feature/login # ⚠️ force delete, even if unmerged
git push -d origin feature/login # delete the branch on the remote too
Good to know
-d refuses if unmerged (safe); -D forces. Remote delete needs a push.
