首页 > 代码库 > Git Note - git tag

Git Note - git tag

git tag is used to create labels, usually for version numbers.
Format: git tag <TagName> <refer>
Example:

git tag v0.1 HEAD

is to create a version number v0.1 on current HEAD.

Notice:
When you git push your code to remote server, you need to add --tags option.

git push --tags

Delete local tags

git tag -d v1.0

Delete remote tags

git push origin :/refs/tags/v1.0