How do you push a tag to a remote repository using Git?

前端 未结 9 1071
滥情空心
滥情空心 2020-11-22 16:31

I have cloned a remote Git repository to my laptop, then I wanted to add a tag so I ran

git tag mytag master

When I run git tag

9条回答
  •  猫巷女王i
    2020-11-22 17:33

    Tags are not sent to the remote repository by the git push command. We need to explicitly send these tags to the remote server by using the following command:

    git push origin 
    

    We can push all the tags at once by using the below command:

    git push origin --tags
    

    Here are some resources for complete details on git tagging:

    http://www.cubearticle.com/articles/more/git/git-tag

    http://wptheming.com/2011/04/add-remove-github-tags

提交回复
热议问题