<?xml version="1.0" encoding="UTF-8"?>

<!--
  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.
-->

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>

  <groupId>org.codehaus.mojo</groupId>
  <artifactId>mojo-parent</artifactId>
  <version>40</version>
  <packaging>pom</packaging>

  <name>MojoHaus Parent</name>
  <description>Parent POM for all MojoHaus hosted Apache Maven plugins and components.</description>
  <url>http://www.mojohaus.org/${project.artifactId}</url>
  <organization>
    <name>MojoHaus</name>
    <url>http://www.mojohaus.org</url>
  </organization>
  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      <distribution>repo</distribution>
    </license>
  </licenses>

  <developers>
    <developer>
      <id>aheritier</id>
      <name>Arnaud Heritier</name>
      <url>https://github.com/aheritier</url>
      <organization>MojoHaus</organization>
      <organizationUrl>https://github.com/mojohaus</organizationUrl>
    </developer>
    <developer>
      <id>Batmat</id>
      <name>Baptiste Mathus</name>
      <url>https://github.com/Batmat</url>
      <organization>MojoHaus</organization>
      <organizationUrl>https://github.com/mojohaus</organizationUrl>
    </developer>
    <developer>
      <id>davidkarlsen</id>
      <name>David Karlsen</name>
      <url>https://github.com/davidkarlsen</url>
      <organization>MojoHaus</organization>
      <organizationUrl>https://github.com/mojohaus</organizationUrl>
    </developer>
    <developer>
      <id>Godin</id>
      <name>Evgeny Mandrikov</name>
      <url>https://github.com/Godin</url>
      <organization>MojoHaus</organization>
      <organizationUrl>https://github.com/mojohaus</organizationUrl>
    </developer>
    <developer>
      <id>khmarbaise</id>
      <name>Karl-Heinz Marbaise</name>
      <url>https://github.com/khmarbaise</url>
      <organization>MojoHaus</organization>
      <organizationUrl>https://github.com/mojohaus</organizationUrl>
    </developer>
    <developer>
      <id>lennartj</id>
      <name>Lennart Jörelid</name>
      <url>https://github.com/lennartj</url>
      <organization>MojoHaus</organization>
      <organizationUrl>https://github.com/mojohaus</organizationUrl>
    </developer>
    <developer>
      <id>mfriedenhagen</id>
      <name>Mirko Friedenhagen</name>
      <url>https://github.com/mfriedenhagen</url>
      <organization>MojoHaus</organization>
      <organizationUrl>https://github.com/mojohaus</organizationUrl>
    </developer>
  </developers>

  <mailingLists>
    <mailingList>
      <name>MojoHaus Development List</name>
      <subscribe>mojohaus-dev+subscribe@googlegroups.com</subscribe>
      <unsubscribe>mojohaus-dev+unsubscribe@googlegroups.com</unsubscribe>
      <post>mojohaus-dev@googlegroups.com</post>
      <archive>https://groups.google.com/forum/#!forum/mojohaus-dev</archive>
    </mailingList>
    <mailingList>
      <name>Maven Users List</name>
      <subscribe>users-subscribe@maven.apache.org</subscribe>
      <unsubscribe>users-unsubscribe@maven.apache.org</unsubscribe>
      <post>users@maven.apache.org</post>
      <archive>http://mail-archives.apache.org/mod_mbox/maven-users/</archive>
      <otherArchives>
        <otherArchive>http://maven.40175.n5.nabble.com/Maven-Users-f40176.html</otherArchive>
      </otherArchives>
    </mailingList>
    <mailingList>
      <name>Former (pre-2015-06) Development List</name>
      <archive>http://markmail.org/list/org.codehaus.mojo.dev</archive>
      <otherArchives>
        <otherArchive>http://mojo.10943.n7.nabble.com/Developer-f3.html</otherArchive>
      </otherArchives>
    </mailingList>
    <mailingList>
      <name>Former (pre-2015-06) User List</name>
      <archive>http://markmail.org/list/org.codehaus.mojo.user</archive>
      <otherArchives>
        <otherArchive>http://mojo.10943.n7.nabble.com/User-f34162.html</otherArchive>
      </otherArchives>
    </mailingList>
    <mailingList>
      <name>Former (pre-2015-06) Commits List</name>
      <archive>http://markmail.org/list/org.codehaus.mojo.scm</archive>
    </mailingList>
    <mailingList>
      <name>Former (pre-2015-06) Announcements List</name>
      <archive>http://markmail.org/list/org.codehaus.mojo.announce</archive>
      <otherArchives>
        <otherArchive>http://mojo.10943.n7.nabble.com/Announce-f38303.html</otherArchive>
      </otherArchives>
    </mailingList>
  </mailingLists>
  <!-- This has NO effect on mojo-projects using this parent.
       This just mean that you need maven 3.0 to build the mojo-parent
       However some of the plugins defined herein have a a prerequisite of
       Maven 3.0, so better use at least Maven 3.0.5
  -->
  <prerequisites>
    <maven>3.0</maven>
  </prerequisites>

  <scm>
    <connection>scm:git:https://github.com/mojohaus/mojo-parent.git</connection>
    <developerConnection>scm:git:ssh://git@github.com/mojohaus/mojo-parent.git</developerConnection>
    <url>https://github.com/mojohaus/mojo-parent</url>
    <tag>mojo-parent-40</tag>
  </scm>
  <issueManagement>
    <system>github</system>
    <url>https://github.com/mojohaus/${project.artifactId}/issues</url>
  </issueManagement>
  <ciManagement>
    <system>travis</system>
    <url>https://travis-ci.org/mojohaus/${project.artifactId}</url>
  </ciManagement>
  <distributionManagement>
    <repository>
      <id>ossrh-staging</id>
      <url>http://oss.sonatype.org/service/local/staging/deploy/maven2</url>
    </repository>
    <snapshotRepository>
      <id>ossrh-snapshots</id>
      <url>http://oss.sonatype.org/content/repositories/snapshots</url>
    </snapshotRepository>
    <site>
      <id>github</id>
      <url>scm:git:ssh://git@github.com/mojohaus/mojo-parent.git</url>
    </site>
  </distributionManagement>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <mojo.javadoc.mavenVersion>${project.prerequisites.maven}</mojo.javadoc.mavenVersion>
    <mojo.java.target>1.7</mojo.java.target>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
    <!-- NOTE: We deliberately do not set maven.test.redirectTestOutputToFile here to workaround MNG-1992 -->
    <surefire.redirectTestOutputToFile>true</surefire.redirectTestOutputToFile>
    <!-- this property makes sure NetBeans 6.8+ picks up some formatting rules from checkstyle -->
    <netbeans.checkstyle.format>true</netbeans.checkstyle.format>
    <maven-javadoc-plugin.version>2.10.4</maven-javadoc-plugin.version>
    <maven-changes-plugin.version>2.11</maven-changes-plugin.version>
    <localCheckout>true</localCheckout>
    <maven-checkstyle-plugin.version>2.16</maven-checkstyle-plugin.version>
    <maven-project-info-reports-plugin.version>2.9</maven-project-info-reports-plugin.version>
  </properties>

  <repositories>
    <repository>
      <id>ossrh-snapshots</id>
      <layout>default</layout>
      <name>ossrh-snapshots</name>
      <releases>
        <enabled>false</enabled>
      </releases>
      <snapshots>
        <checksumPolicy>fail</checksumPolicy>
        <enabled>true</enabled>
      </snapshots>
      <url>http://oss.sonatype.org/content/repositories/snapshots</url>
    </repository>
  </repositories>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>3.0</version>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>4.12</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.plugin-tools</groupId>
        <artifactId>maven-plugin-annotations</artifactId>
        <!--must be same version of m-plugin-p -->
        <version>3.4</version>
      </dependency>      
    </dependencies>
  </dependencyManagement>

  <build>
    <pluginManagement>
      <plugins>
        <!-- Apache plugins in alphabetical order -->
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-antrun-plugin</artifactId>
          <version>1.8</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-assembly-plugin</artifactId>
          <version>2.6</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-checkstyle-plugin</artifactId>
          <version>${maven-checkstyle-plugin.version}</version>
          <configuration>
            <configLocation>config/maven_checks.xml</configLocation>
            <headerLocation>config/maven-header.txt</headerLocation>
          </configuration>
          <dependencies>
            <dependency>
              <groupId>org.apache.maven.shared</groupId>
              <artifactId>maven-shared-resources</artifactId>
              <version>2</version>
            </dependency>
          </dependencies>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-clean-plugin</artifactId>
          <version>3.0.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.5.1</version>
          <configuration>
            <source>${mojo.java.target}</source>
            <target>${mojo.java.target}</target>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-changes-plugin</artifactId>
          <version>${maven-changes-plugin.version}</version>
          <configuration>
            <issueManagementSystems>
              <issueManagementSystem>GitHub</issueManagementSystem>
            </issueManagementSystems>
            <runOnlyAtExecutionRoot>true</runOnlyAtExecutionRoot>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-dependency-plugin</artifactId>
          <version>2.10</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-deploy-plugin</artifactId>
          <version>2.8.2</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-enforcer-plugin</artifactId>
          <version>1.4</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-help-plugin</artifactId>
          <version>2.2</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-gpg-plugin</artifactId>
          <version>1.6</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-install-plugin</artifactId>
          <version>2.5.2</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-invoker-plugin</artifactId>
          <version>2.0.0</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-jar-plugin</artifactId>
          <version>3.0.2</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-war-plugin</artifactId>
          <version>2.6</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-ear-plugin</artifactId>
          <version>2.10.1</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>${maven-javadoc-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-jxr-plugin</artifactId>
          <version>2.5</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-plugin-plugin</artifactId>
          <version>3.4</version>
          <executions>
            <execution>
              <id>help-mojo</id>
              <goals>
                <goal>helpmojo</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-project-info-reports-plugin</artifactId>
          <version>${maven-project-info-reports-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-release-plugin</artifactId>
          <version>2.5.2</version>
          <configuration>
            <!-- do not deploy site but use instructions in README.md -->
            <mavenExecutorId>forked-path</mavenExecutorId>
            <goals>deploy</goals>
            <useReleaseProfile>false</useReleaseProfile>
            <arguments>-Pmojo-release</arguments>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-resources-plugin</artifactId>
          <version>3.0.1</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-scm-publish-plugin</artifactId>
          <version>1.1</version>
          <configuration>
            <pubScmUrl>${project.scm.developerConnection}</pubScmUrl>
            <scmBranch>gh-pages</scmBranch>
            <content>${project.reporting.outputDirectory}</content><!-- mono-module doesn't require site:stage -->
          </configuration>
          <executions>
            <execution>
              <id>scm-publish</id>
              <phase>site-deploy</phase><!-- deploy site with maven-scm-publish-plugin -->
              <goals>
                <goal>publish-scm</goal>
              </goals>
            </execution>
         </executions>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-site-plugin</artifactId>
          <version>3.5.1</version>
          <configuration>
            <skipDeploy>true</skipDeploy><!-- don't deploy site with maven-site-plugin -->
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-source-plugin</artifactId>
          <version>3.0.1</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>2.19.1</version>
          <configuration>
            <redirectTestOutputToFile>${surefire.redirectTestOutputToFile}</redirectTestOutputToFile>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-failsafe-plugin</artifactId>
          <version>2.19.1</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-report-plugin</artifactId>
          <version>2.19.1</version>
        </plugin>
        <!-- Codehaus plugins in alphabetical order -->
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>animal-sniffer-maven-plugin</artifactId>
          <version>1.15</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>cobertura-maven-plugin</artifactId>
          <version>2.7</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>flatten-maven-plugin</artifactId>
          <version>1.0.0-beta-5</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>l10n-maven-plugin</artifactId>
          <version>1.0-alpha-2</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>license-maven-plugin</artifactId>
          <version>1.9</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-maven-plugin</artifactId>
          <version>1.3.8</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>taglist-maven-plugin</artifactId>
          <version>2.4</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>versions-maven-plugin</artifactId>
          <version>2.2</version>
        </plugin>
      </plugins>
    </pluginManagement>
    <plugins>
      <!--
        We need to define the invocation of the plugin here because
        Maven does not pickup the dependencies of checkstyle during
        run of `mvn site` otherwise, see #23.
      -->
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-checkstyle-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <executions>
          <execution>
            <id>mojo-enforcer-rules</id>
            <phase>validate</phase>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <rules>
                <bannedDependencies>
                  <excludes>
                    <exclude>org.codehaus.plexus:plexus-component-api</exclude>
                  </excludes>
                  <message>The plexus-component-api conflicts with the plexus-container-default used by Maven. You probably added a dependency that is missing the exclusions.</message>
                </bannedDependencies>
                <requireNoRepositories>
                  <message>Mojo is synchronized with repo1.maven.org.  The rules for repo1.maven.org are that pom.xml files should not include repository definitions.  If repository definitions are included, they must be limited to SNAPSHOT only repositories.</message>
                  <banRepositories>true</banRepositories>
                  <banPluginRepositories>true</banPluginRepositories>
                  <allowSnapshotRepositories>true</allowSnapshotRepositories>
                  <allowedPluginRepositories>
                    <allowedPluginRepository>ossrh-snapshots</allowedPluginRepository>
                    <allowedPluginRepository>apache.snapshots</allowedPluginRepository>
                  </allowedPluginRepositories>
                </requireNoRepositories>
                <requirePluginVersions>
                  <message>Best Practice is to always define plugin versions!</message>
                  <banLatest>true</banLatest>
                  <banRelease>true</banRelease>
                </requirePluginVersions>
                <requireMavenVersion>
                  <version>(,2.1.0),(2.1.0,2.2.0),(2.2.0,)</version>
                  <message>Maven 2.1.0 and 2.2.0 produce incorrect GPG signatures and checksums respectively.</message>
                </requireMavenVersion>
                <requireProperty>
                  <property>project.scm.developerConnection</property>
                  <!-- because Maven adds the artifactId to the the SCM-Url automatically for modules in a multimodule project,
                  we need to allow stuff after .git.
                  -->
                  <regex>scm:git:ssh://git@github.com/.*\.git.*</regex>
                  <regexMessage>
                    ssh (scm:git:ssh://git@github.com/.*\.git) is the preferred protocol for project.scm.developerConnection, current value: ${project.scm.developerConnection}
                  </regexMessage>
                </requireProperty>
                <requireProperty>
                  <property>project.scm.connection</property>
                  <!-- because Maven adds the artifactId to the the SCM-Url automatically for modules in a multimodule project,
                  we need to allow stuff after .git.
                  -->
                  <regex>scm:git:https://github.com/.*\.git.*</regex>
                  <regexMessage>
                    https (scm:git:https://github.com/.*\.git) is the preferred protocol for project.scm.connection, current value: ${project.scm.connection}
                  </regexMessage>
                </requireProperty>
                <requireProperty>
                  <property>project.scm.url</property>
                  <!-- because Maven adds the artifactId to the the SCM-Url automatically for modules in a multimodule project,
                  we need to allow stuff after .git.
                  -->
                  <regex>https://github.com/.*</regex>
                  <regexMessage>
                    Use https://github.com/.* as project.scm.url, especially using the prefix scm:git here will lead to unbrowseable links during site generation, current value: ${project.scm.url}
                  </regexMessage>
                </requireProperty>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>

  <reporting>
    <plugins>
      <!-- Apache plugins in alphabetical order -->
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-plugin-plugin</artifactId>
        <version>3.4</version>
        <configuration>
          <requirements>
            <!--
            NOTE: Maven 2.x does not interpolate properties of the form project.*|pom.* so the Maven Plugin Plugin
            gets garbage when manually examining the config of the Maven Compiler Plugin.
            -->
            <jdk>${mojo.java.target}</jdk>
          </requirements>
        </configuration>
      </plugin>
    </plugins>
  </reporting>

  <profiles>
    <profile>
      <!--
      On travis-ci, the API rate limit for github reports is sometimes exceeded,
      so only render this when not run on travis.
      -->
      <id>mojo-enable-githubreport-when-not-on-travis</id>
      <activation>
        <property>
          <name>!env.CONTINUOUS_INTEGRATION</name>
        </property>
      </activation>
      <reporting>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-changes-plugin</artifactId>
            <version>${maven-changes-plugin.version}</version>
            <reportSets>
              <reportSet>
                <reports>
                  <report>github-report</report>
                </reports>
              </reportSet>
            </reportSets>
            <configuration>
              <includeOpenIssues>false</includeOpenIssues>
              <onlyMilestoneIssues>true</onlyMilestoneIssues>
              <runOnlyAtExecutionRoot>true</runOnlyAtExecutionRoot>
            </configuration>
          </plugin>
        </plugins>
      </reporting>
    </profile>
    <profile>
      <id>mojo-release</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-assembly-plugin</artifactId>
            <dependencies>
              <dependency>
                <groupId>org.apache.apache.resources</groupId>
                <artifactId>apache-source-release-assembly-descriptor</artifactId>
                <version>1.0.4</version>
              </dependency>
            </dependencies>
            <executions>
              <execution>
                <id>attach-source-release-distro</id>
                <phase>package</phase>
                <goals>
                  <goal>single</goal>
                </goals>
                <configuration>
                  <runOnlyAtExecutionRoot>true</runOnlyAtExecutionRoot>
                  <descriptorRefs>
                    <descriptorRef>source-release</descriptorRef>
                  </descriptorRefs>
                  <tarLongFileFormat>gnu</tarLongFileFormat>
                </configuration>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-deploy-plugin</artifactId>
            <configuration>
              <updateReleaseInfo>true</updateReleaseInfo>
            </configuration>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <executions>
              <execution>
                <id>default-jar-no-fork</id>
                <goals>
                  <goal>jar-no-fork</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
            <configuration>
              <failOnError>false</failOnError>
            </configuration>
            <executions>
              <execution>
                <id>attach-javadocs</id>
                <goals>
                  <goal>jar</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>reporting</id>
      <activation>
        <property>
          <name>skipReports</name>
          <value>!true</value>
        </property>
      </activation>
      <reporting>
        <plugins>
          <!-- Apache plugins in alphabetical order -->
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-checkstyle-plugin</artifactId>
            <version>${maven-checkstyle-plugin.version}</version>
            <configuration>
              <configLocation>config/maven_checks.xml</configLocation>
              <headerLocation>config/maven-header.txt</headerLocation>
            </configuration>
            <reportSets>
              <reportSet>
                <reports>
                  <report>checkstyle</report>
                </reports>
              </reportSet>
            </reportSets>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
            <version>${maven-javadoc-plugin.version}</version>
            <configuration>
              <quiet>true</quiet>
              <links>
                <link>http://junit-team.github.io/junit/javadoc/latest/</link>
              </links>
              <tagletArtifacts>
                <tagletArtifact>
                  <groupId>org.apache.maven.plugin-tools</groupId>
                  <artifactId>maven-plugin-tools-javadoc</artifactId>
                  <version>3.4</version>
                </tagletArtifact>
                <tagletArtifact>
                  <groupId>org.codehaus.plexus</groupId>
                  <artifactId>plexus-component-javadoc</artifactId>
                  <version>1.5.5</version>
                </tagletArtifact>
              </tagletArtifacts>
            </configuration>
            <reportSets>
              <reportSet>
                <reports>
                  <report>javadoc</report>
                  <report>test-javadoc</report>
                </reports>
              </reportSet>
            </reportSets>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-jxr-plugin</artifactId>
            <version>2.5</version>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-pmd-plugin</artifactId>
            <version>3.5</version>
            <configuration>
              <targetJdk>${mojo.java.target}</targetJdk>
              <excludeRoots>
                <excludeRoot>${project.build.directory}/generated-sources/antlr</excludeRoot>
                <excludeRoot>${project.build.directory}/generated-sources/javacc</excludeRoot>
                <excludeRoot>${project.build.directory}/generated-sources/modello</excludeRoot>
                <excludeRoot>${project.build.directory}/generated-sources/plugin</excludeRoot>
              </excludeRoots>
            </configuration>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-project-info-reports-plugin</artifactId>
            <version>${maven-project-info-reports-plugin.version}</version>
            <reportSets>
              <reportSet>
                <reports>
                  <report>cim</report>
                  <report>dependencies</report>
                  <report>dependency-convergence</report>
                  <report>dependency-info</report>
                  <report>dependency-management</report>
                  <report>index</report>
                  <report>issue-tracking</report>
                  <report>license</report>
                  <report>mailing-list</report>
                  <report>plugin-management</report>
                  <report>project-team</report>
                  <report>scm</report>
                  <report>summary</report>
                </reports>
              </reportSet>
            </reportSets>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-report-plugin</artifactId>
            <version>2.19.1</version>
            <reportSets>
              <reportSet>
                <reports>
                  <report>report</report>
                </reports>
              </reportSet>
            </reportSets>
          </plugin>
          <!-- Codehaus plugins in alphabetical order -->
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>cobertura-maven-plugin</artifactId>
            <version>2.6</version>
            <configuration>
              <instrumentation>
                <excludes>
                  <exclude>**/HelpMojo.class</exclude>
                </excludes>
              </instrumentation>
            </configuration>
          </plugin>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>taglist-maven-plugin</artifactId>
            <version>2.4</version>
          </plugin>
        </plugins>
      </reporting>
    </profile>
    <profile>
      <id>maven-3</id>
      <activation>
        <file>
          <!-- This employs that the basedir expression is only recognized by Maven 3.x (see MNG-2363) -->
          <exists>${basedir}</exists>
        </file>
      </activation>
      <build>
        <plugins>
          <!-- if releasing current pom with maven 3 site descriptor must be attached -->
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-site-plugin</artifactId>
            <inherited>false</inherited>
            <executions>
              <execution>
                <id>attach-descriptor</id>
                <goals>
                  <goal>attach-descriptor</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>codecoverage</id>
      <activation>
        <activeByDefault>true</activeByDefault>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>cobertura-maven-plugin</artifactId>
            <executions>
              <execution>
                <goals>
                  <goal>clean</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
