Skip to content

Instantly share code, notes, and snippets.

@Ravendwyr
Created February 15, 2015 19:30
Show Gist options
  • Save Ravendwyr/5341f6f41148a26f1729 to your computer and use it in GitHub Desktop.
Save Ravendwyr/5341f6f41148a26f1729 to your computer and use it in GitHub Desktop.
Replace all git tags with annotated git tags.
#! /bin/sh
git tag -l | while read tag; do git checkout $tag; git tag -d $tag; GIT_COMMITTER_DATE="$(git show --format=%aD | head -1)" git tag -a $tag -m "Tagging as $tag."; git push origin :refs/tags/$tag; done
git push --tags
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment