I'm trying to delete a remote git branch with
git push origin :my_remote_branch
error: unable to push to unqualified destination: my_remote_branch
The destination refspec neither matches an existing ref on the remote nor
begins with refs/, and we are unable to guess a prefix based on the source ref.
error: failed to push some refs to 'firstname.lastname@example.org:/myrepo'
git branch -a
remotes/origin/HEAD -> origin/master
git branch -r --merged
origin/HEAD -> origin/master
The fact that
refs/remotes/origin/my_remote_branch exists in your local repository does not imply
refs/heads/my_remote_branch exists in the
origin remote repository.
git fetch -p origin to make
refs/remotes/origin/my_remote_branch go away if it's already deleted in origin. The
-p option tells fetch to delete any tracking branches that no longer exist in the corresponding remotes; by default they are kept around.