Skip to contentSkip to conversation

Cloning tags from master

DISCUSSION dquince 2 participants 2 messages Jun 15, 2016

lore
Share & tools
lore

dquince

author
#0 lore raw

I am trying to implement using tags in our build process, but am running into an issue with pulling tags from master. My scenario is as follows We decide on a release and I tag master with testtag which has commit testtag-1-gf3b117e
When I make another commit to master and check the tag, I see it as testtag-2-gfb56442
When I try and pull the tag using testtag, it just wants to pull the latest commit to master.

I verified this works in branches other than master, so can this be done from master or does the tag just follow the head?

--
View this message in context: http://git.661346.n2.nabble.com/Cloning-tags-from-master-tp7569301.html
Sent from the git mailing list archive at Nabble.com.

#1 lore raw
Quoted 6 lines · dquince

I am trying to implement using tags in our build process, but am running into an issue with pulling tags from master. My scenario is as follows We decide on a release and I tag master with testtag which has commit testtag-1-gf3b117e
When I make another commit to master and check the tag, I see it as testtag-2-gfb56442

I don't know what you mean by "check the tag", but those look like the output of "git describe" when HEAD is one or two commits ahead of testtag (with no tags that are closer).

Quoted 2 lines

When I try and pull the tag using testtag, it just wants to pull the latest commit to master.

You're probably not running "git pull origin refs/tags/testtag", but I think that's the only way to "pull the tag," so I don't know what you're doing here. The tag doesn't include anything that's not part of the tag's history, though, so "pulling" it won't get the latest version of anything.

Quoted 2 lines

I verified this works in branches other than master, so can this be done from master or does the tag just follow the head?

Tags never follow anything. Once they're created, they stay put.

-PJ

Gehm's Corollary to Clark's Law: Any technology distinguishable from magic is insufficiently advanced.