When I push from TortoiseGit, tags are not included by default. In a recent update, however, an option was added to help with this. There is now a check box in the push dialog to "include tags". How do I set this to enabled by default?
I don't want to forget to add the check when I want to push a tag. A this point, I don't use any tags locally which I don't want to push and thus share with other developers.
I tried adding
[push]
followTags = true
to my gitconfig file (local, global, systemwide, tgitconfig...) which TortoiseGit lets you edit from Settings->Git, but that neither set the switch, nor performed the action when I pushed...
Right click on the commit you want to tag, and click Create Tag at this version... Back to Log Message dialog, right click on that tag label, click Push "tag_name"...
Sharing tags is similar to pushing branches. By default, git push will not push tags. Tags have to be explicitly passed to git push .
Sharing Tags You will have to explicitly push tags to a shared server after you have created them. This process is just like sharing remote branches — you can run git push origin <tagname> . If you have a lot of tags that you want to push up at once, you can also use the --tags option to the git push command.
The git push command is used to upload local repository content to a remote repository. Pushing is how you transfer commits from your local repository to a remote repo. It's the counterpart to git fetch , but whereas fetching imports commits to local branches, pushing exports commits to remote branches.
As of today TortoiseGit (v. 2.1.0) doesn't remember the "push tags" state.
However, as a workaround you can configure your remote you push to to always push all tags, e.g. put something like that in your .git/config
:
[remote "origin"]
url = ...
push = ... (your old push line)
push = +refs/tags/*:refs/tags/*
The +
at the beginning indicates to force push all remote tags (remove the prefix in order to prevent that).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With