Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do you remove a tag from a remote repository

Tags:

git

Is it possible to untag a revision that has been push upstream using git.

This is what has happened:

 git tag 1.1  git push --tags origin master 

Doh! That was meant to be version 1.1beta

Can you rebase and repush upstream. No other member of my team has pulled from origin yet.

like image 474
serby Avatar asked May 27 '11 12:05

serby


People also ask

How do I remove old tags from github?

To delete a local git tag simply run the "git tag" command with the -d option and tag name. To know the tag name you can run the "git tag" command with the -l option to list all tags, identify the tag you want to delete.

Which command used to remove a tag in local repository?

Install the gem, then run "git sync-local-tags" in your repository to delete the local tags that do not exist on the remote.


2 Answers

You can delete a remote tag the same way that you delete a remote branch.

git push origin :1.1 

And delete your local tag with:

git tag -d 1.1 
like image 110
Abizern Avatar answered Oct 20 '22 05:10

Abizern


git push --delete origin TAGNAME 

Of course, you still have to delete the tag locally by running:

git tag -d TAGNAME 
like image 45
Flimm Avatar answered Oct 20 '22 05:10

Flimm