o Start of a POM validation procedure for a release.

git-svn-id: https://svn.apache.org/repos/asf/maven/maven-1/plugins/trunk@112812 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
jvanzyl 2003-02-02 16:02:30 +00:00
parent 8cd4b0fb59
commit 581940bc09

View File

@ -35,4 +35,44 @@
| of the latest snapshot.
-->
<!--
|
| Convert SNAPSHOT version identifiers to real snapshot versions.
| You cannot leave SNAPSHOT version identifiers in the POM for a
| release.
|
-->
<goal name="convert-snapshots">
</goal>
<!--
|
| Validate the POM for a release. This consists of:
|
| 1) Making sure all SNAPSHOT version identifiers are converted.
|
-->
<goal name="validate-pom-for-release">
<j:useBean var="snapshots" class="java.util.ArrayList"/>
<j:forEach var="dependency" items="${pom.dependencies}">
<j:if test="${dependency.version == 'SNAPSHOT'}">
<j:set var="dummy" value="${snapshots.add(dependency)}"/>
</j:if>
</j:forEach>
<j:if test="${size(snapshots) > 0}">
<echo/>
<echo>The following dependencies have SNAPSHOT identifiers:</echo>
<echo/>
<j:forEach var="dependency" items="${snapshots}">
<echo>${dependency.artifactId}</echo>
</j:forEach>
<fail message="">
</fail>
</j:if>
</goal>
</project>