Delete Remote Git Tag

Here is how to delete a tag from a remote Git repository.

If you have a tag named ‘6.x-2.0’ then you would just do this:

git tag -d 6.x-2.0
git push origin :refs/tags/6.x-2.0

That will remove ‘6.x-2.0’ from the remote repository.

To add it back, like in the Password Trigger Drupal module:

git checkout 6.x-2.x
git tag -a 6.x-2.0 -m "Switch to use Drupal core triggers and actions. Optionally allows Token module to enhance outgoing email."
git push origin 6.x-2.0