LinuxCommandLibrary

git-tag

Create, list, and manage tags

TLDR

List tags

$ git tag
copy
Create lightweight tag
$ git tag [name]
copy
Create annotated tag
$ git tag -a [name] -m "[message]"
copy
Create signed tag
$ git tag -s [name] -m "[message]"
copy
Tag specific commit
$ git tag [name] [commit]
copy
Delete tag
$ git tag -d [name]
copy
Push tag to remote
$ git push origin [name]
copy
List tags matching pattern
$ git tag -l "[v1.*]"
copy

SYNOPSIS

git tag [options] [name] [commit]

DESCRIPTION

git tag creates, lists, deletes, and verifies tag objects. Tags mark specific points in history as important, typically used for release versions.
Lightweight tags are simple pointers to a commit, while annotated tags store extra metadata such as the tagger name, date, and a message. Signed tags add a GPG signature for verification.

PARAMETERS

-a, --annotate

Create annotated tag.
-m, --message msg
Tag message.
-s, --sign
Create signed tag.
-d, --delete
Delete tag.
-f, --force
Force replace tag.
-l, --list pattern
List matching tags.
-n num
Show lines of annotation.
--contains commit
Tags containing commit.
--sort key
Sort tags.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community