Actions
JenkinsGroovy » History » Revision 6
« Previous |
Revision 6/28
(diff)
| Next »
Andreas Kohlbecker, 08/14/2013 11:06 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:
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 · 6 revisions