git-tag

How is a tag different from a branch in Git? Which should I use, here?

ぃ、小莉子 提交于 2019-11-26 01:50:10
问题 I am having some difficulty understanding how to use tags versus branches in git. I just moved the current version of our code from cvs to git, and now I\'m going to be working on a subset of that code for a particular feature. A few other developers will be working on this as well, but not all developers in our group are going to care about this feature. Should I be creating a branch or a tag? In what situations should I be using one versus the other? 回答1: A tag represents a version of a

Download a specific tag with Git

蓝咒 提交于 2019-11-26 01:34:19
问题 I\'m trying to figure out how I can download a particular tag of a Git repository - it\'s one version behind the current version. I saw there was a tag for the previous version on the git web page, with object name of something long hex number. But the version name is \" Tagged release 1.1.5 \" according the site. I tried a command like this (with names changed): git clone http://git.abc.net/git/abc.git my_abc And I did get something - a directory, a bunch of subdirectories, etc. If it\'s the

How to get the latest tag name in current branch in Git?

送分小仙女□ 提交于 2019-11-26 00:35:35
问题 What\'s the simplest way to get the most recent tag in Git? git tag a HEAD git tag b HEAD^^ git tag c HEAD^ git tag output: a b c Should I write a script to get each tag\'s datetime and compare them? 回答1: You could take a look at git describe , which does something close to what you're asking. 回答2: To get the most recent tag: git describe --tags To get the most recent annotated tag: git describe --abbrev=0 回答3: Will output the tag of the latest tagged commit across all branches git describe -

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

瘦欲@ 提交于 2019-11-26 00:35:00
问题 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 on my laptop the tag mytag is shown. I then want to push this to the remote repository so I have this tag on all my clients, so I run git push but I got the message: Everything up-to-date And if I go to my desktop and run git pull and then git tag no tags are shown. I have also tried to do a minor change on a file in the project, then push it to the server. After