blob: 8dd86686f33a54e2490e8f1bca1159b2b4acd39f [file] [log] [blame]
------
Validate Your changes.xml File
------
Olivier Lamy
------
2011-03-30
------
~~ Licensed to the Apache Software Foundation (ASF) under one
~~ or more contributor license agreements. See the NOTICE file
~~ distributed with this work for additional information
~~ regarding copyright ownership. The ASF licenses this file
~~ to you under the Apache License, Version 2.0 (the
~~ "License"); you may not use this file except in compliance
~~ with the License. You may obtain a copy of the License at
~~
~~ http://www.apache.org/licenses/LICENSE-2.0
~~
~~ Unless required by applicable law or agreed to in writing,
~~ software distributed under the License is distributed on an
~~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
~~ KIND, either express or implied. See the License for the
~~ specific language governing permissions and limitations
~~ under the License.
~~ NOTE: For help with the syntax of this file, see:
~~ http://maven.apache.org/doxia/references/apt-format.html
Validate Your changes.xml File
Since 2.1, a {{{../changes-validate-mojo.html}goal}} is
provided to validate your <<<changes.xml>>> file.
You can attach this goal to the <<<pre-site>>> phase if you want the
validation to be performed automatically when you generate the site.
* Configuring the Plugin
First you must configure the plugin and tell it to validate your <<<changes.xml>>> file.
+-----------------+
<project>
...
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-changes-plugin</artifactId>
<version>${project.version}</version>
<executions>
<execution>
<id>validate-changes</id>
<phase>pre-site</phase>
<goals>
<goal>changes-validate</goal>
</goals>
<configuration>
<!-- if set to true the build will fail if the changes file is invalid,
if set to false warnings will be logged. -->
<failOnError>true</failOnError>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
...
</project>
+-----------------+