Reputation: 891
We would like to set up TeamCity to monitor our tag directory and automatically build when a new tag is created.
This means that when we have a version ready for release all we need to do is create a tag and TeamCity can then take care of our build, deploy etc.
Currently the only solution is to have a relase branch which we then copy the tag to after we have created it. Ideally we would like to remove this extra step.
Upvotes: 8
Views: 1792
Reputation: 891
I don't think there is a perfect solution to the question, although @sijw does provide an answer that involves the least manual steps.
The reason for this was so we could get the latest tag to deploy to nexus using maven. However I think we are doing this in the wrong way.
It turns out that using Maven release can create an SVN tag for you as well as deploying to Nexus when you create a new version. Rather than creating the tag first and then deoplying from that.
Perhaps anyone looking for an answer to this question should look into Maven release as a solution. (http://maven.apache.org/guides/mini/guide-releasing.html)
Upvotes: 0
Reputation: 2446
Not sure it can be done as you described as TC wouldn't know what the latest tag is; unless you have an actual Latest
tag which you overwrite each time which is quite common.
Only way I can think to reduce manual work is to perhaps setup your TC Project VSC Root to point at myProj/tags/
then set the check-out rule to +:v1.2.3.4
where v1.2.3.4
is the name of your latest tag.
So when you create a new tag, just update the check-out rule to point at it then hit the build button.
Upvotes: 2