Skip to content

Tagging

Zhamri Che Ani edited this page Jan 3, 2022 · 5 revisions

How to:

Listing Your Tags

+  $ git tag
-  $ git tag --list "v2.7.5*"
   $ git show v2.7.7

Creating Lightweight Tags

  $ git tag <tag_name> 

eg: 
  $ git tag v1.0

Creating Annotated Tags

  $ git tag -a <tag_name> -m "<tag_message>"

eg: 
  $ git tag -a v1.0 -m "Version 1.0"

Tagging Later

  $ git tag -a <tag_name> <commit_checksum>

eg: 
  $ git tag -a v1.0 9fceb02

Sharing Tag

  $ git push origin <tag_name>

eg:
  $ git push origin v1.0

Sharing All Tags

  $ git push origin --tags

References:

  1. https://git-scm.com/book/en/v2/Git-Basics-Tagging
  2. https://git-scm.com/docs/git-tag
  3. https://semver.org/
  4. https://github.com/facebook/react
  5. https://github.com/microsoft/vscode