Actions
JenkinsGroovy » History » Revision 7
« Previous |
Revision 7/28
(diff)
| Next »
Andreas Kohlbecker, 08/14/2013 11:12 PM
Groovy Scripts for Jenkins¶
You can evaluate groovy scripts in the Jenkins Script Console.
There are several plugins which can be programmed with Groovy:
Get all versions of an artifact from a maven repository¶
def metadata = new XmlSlurper().parse("http://wp5.e-taxonomy.eu/mavenrepo/eu/etaxonomy/cdm-server/maven-metadata.xml") metadata.versioning.versions.version.each{ println "> " + it }
doc:
the same for the Dynamic Parameter Plug-in which is very nice in conjunction with the *Repository Connector Plugin
def metadata = new XmlSlurper().parse("http://wp5.e-taxonomy.eu/mavenrepo/eu/etaxonomy/cdm-server/maven-metadata.xml") def list = [] metadata.versioning.versions.version.each{ list.add(it) } return list
Updated by Andreas Kohlbecker over 10 years ago · 7 revisions