Hi, I'm not sure if you still need an answer to this but I recently had to 
do something similar and this is what I did to make it work...

In your Jenkins job, choose "Prepare an environment for the run" option and 
add to "Script Content" something like this:
-----
export SVN_TAG=`svn ls --username someuser --password somepass 
--non-interactive http://someproj.googlecode.com/svn/tags |tail -1`
echo "SVN_TAG=$SVN_TAG" >propsfile
-----

You can then use the repo url under SCM as you've listed above... 
http://someproj.googlecode.com/svn/tags/$SVN_TAG

Finally, under Build Environment, choose "Inject environment variables to 
the build process" and enter "propsfile" for "Properties File Path".

Good luck!
Nilesh.

On Tuesday, June 19, 2012 at 5:07:51 AM UTC-7, Martin Grotzke wrote:
>
> Hi, 
>
> I want jenkins to automatically select the latest tag for a build. 
>
> I have configured the build parameter 
>
> "List Subversion Tags" with 
> Name = SVN_TAG 
> Repository URL = http://someproj.googlecode.com/svn/tags 
> Maximum tags to display = 1 
> Sort newest first = true 
>
> The Source Code Management / Subversion is configured with 
> Repository URL = http://someproj.googlecode.com/svn/tags/$SVN_TAG 
>
> When I trigger a build (manually) jenkins tells me that "This build 
> requires parameters:" and provides a drop down for SVN_TAG with a single 
> value. 
> Instead, I expect jenkins to build this tag automatically. 
>
> I have also configured "Poll SCM" as build trigger, and the subversion 
> polling log tells that 
>   "Location 'http://reflectasm.googlecode.com/svn/tags/$SVN_TAG' does 
> not exist" 
>
> Is it possible to automatically build the latest svn tag, what's the 
> correct configuration for this? 
>
> Thanx && cheers, 
> Martin 
>

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/e6d4acae-20c6-4918-99a6-98e46d0a1065%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to