Why can't I delete a remote branch in BitBucket?
When I try to do
git push origin :foo-branch', I get an error:
error: unable to delete 'foo-branch': remote ref does not exist error: failed to push some refs to 'firstname.lastname@example.org:username/repo-name.git'
I know the branch exist, because:
- how to manage project variations as well as development flow with Git?
- Git went back 5 commits and forgot to create a new branch, how to come back?
- How to keep multiple copies of a file in single Git branch?
- How do I commit only some files?
- git switch branch without discarding local changes
- Can I push hotfix to a tag in git
- I see it in
git log --all;
- I see it in the web interface on BitBucket
What’s more, even after I run
git remote prune origin, I can still see it, when I run
git branch -a:
I have also tried
git fetch -p origin and still couldn’t solve this problem.