What's this in the yellow round box?
git branch -D,
git tag -d but none succeeded. So how to delete it?
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.Sign up to join this community
Alexey Ten has the better answer for this because it handles branches, tags, and packed refs. Future visitors should try that solution before this one.
If it's a tag, the following command ought to work:
git tag -d refs/original/refs/heads/master
But, since you've said it doesn't, you can just delete the file out of the
.git directory. From the repository root, a command like this will get it:
The path may be slightly different if the
git-tag command failed, so you may want to
cd .git/refs and find the offending head by trial-and-error. Deleting the file will remove the reference from your local repository.
This is a ref. Normally created by
git filter-branch - it is a pointer to where your branch was before you ran
And to delete any ref, you can always push nothing to it in the local repository:
git push . :refs/original/refs/heads/master
The other answers also covered pretty well other ways of deleting.