| title | Signing tags | ||||||
|---|---|---|---|---|---|---|---|
| intro | You can sign tags locally using GPG, SSH, or S/MIME. | ||||||
| redirect_from |
|
||||||
| versions |
|
||||||
| category |
|
{% data reusables.gpg.desktop-support-for-commit-signing %}
Tip
To configure your Git client to sign tags by default for a local repository, in Git versions 2.23.0 and above, run git config tag.gpgsign true. To sign all tags by default in any local repository on your computer, run git config --global tag.gpgsign true.
-
To sign a tag, add
-sto yourgit tagcommand.$ git tag -s MYTAG # Creates a signed tag -
Verify your signed tag by running
git tag -v [tag-name].$ git tag -v MYTAG # Verifies the signed tag