How can I get an XML Site with Maven or Ant?



I am trying to get the revision of the last stable hudson build in order th build a stable release. Currently I use the Hudson API and Maven with Ant:



<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>download-files</id>
<phase>prepare-package</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<get src="http://hudson/job/CI/lastSuccessfulBuild/api/xml?xpath=/freeStyleBuild/changeSet/revision/revision"
dest="C:/test.xml"
/>
</target>
</configuration>
</execution>
</executions>


But ant doesn't get the xml... Has anybody an idea?


Tiada ulasan:

Catat Ulasan