<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ Copyright 2015 Lukas Krejci
  ~
  ~ Licensed 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.revapi</groupId>
    <artifactId>revapi-parent</artifactId>
    <version>15</version>
    <packaging>pom</packaging>
    <name>Revapi parent</name>
    <description>Parent POM for revapi projects. Common deps and site.</description>
    <url>https://revapi.org</url>
    <inceptionYear>2014</inceptionYear>
    <organization>
        <name>Lukas Krejci</name>
        <url>http://lukas.krejci.pw</url>
    </organization>
    <licenses>
        <license>
            <name>Apache License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>
    <developers>
        <developer>
            <name>Lukas Krejci</name>
            <email>revapi@krejci.pw</email>
            <url>http://lukas.krejci.pw</url>
            <timezone>+1</timezone>
        </developer>
    </developers>
    <mailingLists>
        <mailingList>
            <name>Revapi</name>
            <subscribe>https://groups.google.com/forum/#!forum/revapi</subscribe>
            <unsubscribe>https://groups.google.com/forum/#!forum/revapi</unsubscribe>
            <post>mailto:revapi@googlegroups.com</post>
            <archive>https://groups.google.com/forum/#!forum/revapi</archive>
        </mailingList>
    </mailingLists>
    <scm>
        <connection>scm:git:git://github.com/revapi/revapi.git</connection>
        <developerConnection>scm:git:ssh://git@github.com/revapi/revapi.git</developerConnection>
        <tag>HEAD</tag>
        <url>https://github.com/revapi/revapi</url>
    </scm>
    <issueManagement>
        <system>github-issues</system>
        <url>https://github.com/revapi/revapi/issues</url>
    </issueManagement>
    <ciManagement>
        <system>travis</system>
        <url>http://travis-ci.org/revapi/revapi</url>
    </ciManagement>
    <distributionManagement>
        <repository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <site>
            <id>site</id>
            <url>https://revapi.org</url>
        </site>
    </distributionManagement>
    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <version.build-helper-maven-plugin>3.0.0</version.build-helper-maven-plugin>
        <version.findbugs-maven-plugin>3.0.0</version.findbugs-maven-plugin>
        <version.formatter-maven-plugin>2.13.0</version.formatter-maven-plugin>
        <version.impsort-maven-plugin>1.4.1</version.impsort-maven-plugin>
        <version.jacoco-maven-plugin>0.8.7</version.jacoco-maven-plugin>
        <version.license-maven-plugin>3.0</version.license-maven-plugin>
        <version.maven-antrun-plugin>3.0.0</version.maven-antrun-plugin>
        <version.maven-assembly-plugin>2.5.5</version.maven-assembly-plugin>
        <version.maven-checkstyle-plugin>3.0.0</version.maven-checkstyle-plugin>
        <version.maven-compiler-plugin>3.8.1</version.maven-compiler-plugin>
        <version.maven-enforcer-plugin>3.0.0-M3</version.maven-enforcer-plugin>
        <version.maven-failsafe-plugin>${version.maven-surefire-plugin}</version.maven-failsafe-plugin>
        <version.maven-jar-plugin>3.2.0</version.maven-jar-plugin>
        <version.maven-javadoc-plugin>3.2.0</version.maven-javadoc-plugin>
        <version.maven-project-info-reports-plugin>3.1.1</version.maven-project-info-reports-plugin>
        <version.maven-release-plugin>2.5.1</version.maven-release-plugin>
        <version.maven-resources-plugin>3.2.0</version.maven-resources-plugin>
        <version.maven-shade-plugin>3.2.4</version.maven-shade-plugin>
        <version.maven-site-plugin>3.9.1</version.maven-site-plugin>
        <version.maven-source-plugin>3.2.0</version.maven-source-plugin>
        <version.maven-surefire-plugin>3.0.0-M5</version.maven-surefire-plugin>
        <version.sortpom-maven-plugin>2.13.1</version.sortpom-maven-plugin>
        <version.versions-maven-plugin>2.8.1</version.versions-maven-plugin>
    </properties>
    <build>
        <!-- Sigh - https://jira.codehaus.org/browse/MNG-5588 -->
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>build-helper-maven-plugin</artifactId>
                    <version>${version.build-helper-maven-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>findbugs-maven-plugin</artifactId>
                    <version>${version.findbugs-maven-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>net.revelc.code.formatter</groupId>
                    <artifactId>formatter-maven-plugin</artifactId>
                    <version>${version.formatter-maven-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>net.revelc.code</groupId>
                    <artifactId>impsort-maven-plugin</artifactId>
                    <version>${version.impsort-maven-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.jacoco</groupId>
                    <artifactId>jacoco-maven-plugin</artifactId>
                    <version>${version.jacoco-maven-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>com.mycila</groupId>
                    <artifactId>license-maven-plugin</artifactId>
                    <version>${version.license-maven-plugin}</version>
                </plugin>
                <plugin>
                    <artifactId>maven-antrun-plugin</artifactId>
                    <version>${version.maven-antrun-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-checkstyle-plugin</artifactId>
                    <version>${version.maven-checkstyle-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>${version.maven-compiler-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-enforcer-plugin</artifactId>
                    <version>${version.maven-enforcer-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <version>${version.maven-failsafe-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>${version.maven-jar-plugin}</version>
                </plugin>
                <plugin>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>${version.maven-javadoc-plugin}</version>
                </plugin>
                <plugin>
                    <artifactId>maven-project-info-reports-plugin</artifactId>
                    <version>${version.maven-project-info-reports-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>${version.maven-release-plugin}</version>
                </plugin>
                <plugin>
                    <artifactId>maven-resources-plugin</artifactId>
                    <version>${version.maven-resources-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-shade-plugin</artifactId>
                    <version>${version.maven-shade-plugin}</version>
                </plugin>
                <plugin>
                    <artifactId>maven-site-plugin</artifactId>
                    <version>${version.maven-site-plugin}</version>
                    <configuration>
                        <skipDeploy>true</skipDeploy>
                    </configuration>
                </plugin>
                <plugin>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>${version.maven-source-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>${version.maven-surefire-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>com.github.ekryd.sortpom</groupId>
                    <artifactId>sortpom-maven-plugin</artifactId>
                    <version>${version.sortpom-maven-plugin}</version>
                </plugin>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>versions-maven-plugin</artifactId>
                    <version>${version.versions-maven-plugin}</version>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <artifactId>maven-enforcer-plugin</artifactId>
                <executions>
                    <execution>
                        <id>ban-mad-gadget</id>
                        <goals>
                            <goal>enforce</goal>
                        </goals>
                        <configuration>
                            <rules>
                                <bannedDependencies>
                                    <excludes>
                                        <exclude>commons-collections:commons-collections:[3.0,3.2.1]</exclude>
                                        <exclude>commons-collections:commons-collections:4.0</exclude>
                                    </excludes>
                                </bannedDependencies>
                            </rules>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>com.github.ekryd.sortpom</groupId>
                <artifactId>sortpom-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <phase>validate</phase>
                        <goals>
                            <goal>sort</goal>
                        </goals>
                        <configuration>
                            <sortDependencies>artifactId,groupId</sortDependencies>
                            <sortExecutions>false</sortExecutions>
                            <sortModules>true</sortModules>
                            <sortPlugins>artifactId,groupId</sortPlugins>
                            <sortProperties>true</sortProperties>
                            <nrOfIndentSpace>4</nrOfIndentSpace>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
    <reporting>
        <plugins>
            <plugin>
                <artifactId>maven-project-info-reports-plugin</artifactId>
                <reportSets>
                    <reportSet>
                        <reports></reports>
                    </reportSet>
                </reportSets>
            </plugin>
        </plugins>
    </reporting>
    <profiles>
        <profile>
            <id>fast</id>
            <properties>
                <checkstyle.skip>true</checkstyle.skip>
                <enforcer.skip>true</enforcer.skip>
                <formatter.skip>true</formatter.skip>
                <impsort.skip>true</impsort.skip>
                <jacoco.skip>true</jacoco.skip>
                <license.skip>true</license.skip>
                <revapi.skip>true</revapi.skip>
                <skipTests>true</skipTests>
                <sort.skip>true</sort.skip>
            </properties>
        </profile>
        <profile>
            <id>next-versions</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.codehaus.mojo</groupId>
                        <artifactId>versions-maven-plugin</artifactId>
                        <configuration>
                            <generateBackupPoms>false</generateBackupPoms>
                            <allowSnapshots>true</allowSnapshots>
                            <excludeReactor>false</excludeReactor>
                            <includes>
                                <item>org.revapi:*</item>
                            </includes>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>release-versions</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.codehaus.mojo</groupId>
                        <artifactId>versions-maven-plugin</artifactId>
                        <configuration>
                            <generateBackupPoms>false</generateBackupPoms>
                            <allowSnapshots>false</allowSnapshots>
                            <allowDowngrade>true</allowDowngrade>
                            <excludeReactor>true</excludeReactor>
                            <includes>
                                <item>org.revapi:*</item>
                            </includes>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>1.5</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <artifactId>maven-source-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
