{"thread":{"id":"16644","subject":"Howto remove accidentally fetched remote tags?","startedAt":"2008-12-09T03:34:43Z","lastAt":"2008-12-09T06:03:39Z","messageCount":2,"participants":["roylee17","Jeff King"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"97395","messageId":"1228793683956-1632369.post@n2.nabble.com","threadId":"16644","inReplyTo":null,"subject":"Howto remove accidentally fetched remote tags?","fromName":"roylee17","fromEmail":"roylee17@gmail.com","sentAt":"2008-12-09T03:34:43Z","receivedAt":"2008-12-09T03:34:43Z","isPatch":false,"sender":{"key":"roylee17@gmail.com","avatar":null},"body":"\nHi,\n\nIs there a convenient way to remove tags which accidentally( forgot adding\n--no-tag ) fetched from a remote repo?\n\nWill git add tag namespace( like branch namespace) in the future?\nIn this case, we can manage tags as convenient as branches.\n\nThanks.\n\nRoy\n-- \nView this message in context: http://n2.nabble.com/Howto-remove-accidentally-fetched-remote-tags--tp1632369p1632369.html\nSent from the git mailing list archive at Nabble.com.\n"},{"id":"97401","messageId":"20081209060339.GA3174@coredump.intra.peff.net","threadId":"16644","inReplyTo":"1228793683956-1632369.post@n2.nabble.com","subject":"Re: Howto remove accidentally fetched remote tags?","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2008-12-09T06:03:39Z","receivedAt":"2008-12-09T06:03:39Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Mon, Dec 08, 2008 at 07:34:43PM -0800, roylee17 wrote:\n\n> Is there a convenient way to remove tags which accidentally( forgot adding\n> --no-tag ) fetched from a remote repo?\n\nHow about\n\n  $ git tag -l >tags-to-delete\n  $ $EDITOR tags-to-delete\n  $ xargs git tag -d <tags-to-delete\n\n?\n\n> Will git add tag namespace( like branch namespace) in the future?\n> In this case, we can manage tags as convenient as branches.\n\nI don't think there any plans for it. You can get something close by\ndoing this:\n\n  $ git config --add remote.origin.fetch '+refs/tags/*:refs/tags/origin/*'\n  $ git config remote.origin.tagopt --no-tags\n\nThe big difference is that you are asking to fetch _all_ tags here,\nwhereas the usual tag operation is to grab tags that point to anything\nyou are already getting via branches. But in practice, that is usually\nthe same content anyway.\n\n-Peff\n"}]}