Created
November 28, 2017 18:37
-
-
Save AhiyaHiya/aaf5b0ec8da488bd7daa3194a0b2139e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| set -e | |
| set -u | |
| # https://stackoverflow.com/questions/1028649/how-do-you-rename-a-git-tag | |
| # old_name new_name | |
| rename_git_tag() | |
| { | |
| local readonly old=$1 | |
| local readonly new=$2 | |
| git tag $new $old | |
| git tag -d $old | |
| } | |
| push_git_tag_to_origin() | |
| { | |
| local readonly old=$1 | |
| git push origin :refs/tags/$old | |
| git push --tags | |
| } | |
| rename_git_tag "oldtagname" "feature/newtagname" | |
| push_git_tag_to_origin "oldtagname" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment