<!--
  TecSinapse OSS Parent - Parent POM for TecSinapse Open Source

  License: GNU Lesser General Public License (LGPL), version 3 or later
  See the LICENSE file in the root directory or <http://www.gnu.org/licenses/lgpl-3.0.html>.
  -->
<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>br.com.tecsinapse</groupId>
    <artifactId>tecsinapse-oss-parent</artifactId>
    <version>2.0.2</version>
    <packaging>pom</packaging>

    <name>${project.groupId}:${project.artifactId}</name>

    <description>${project.artifactId} is the parent Maven POM for TecSinapse open source projects.</description>

    <url>https://github.com/tecsinapse/tecsinapse-oss-parent</url>

    <licenses>
        <license>
            <name>FSF Lesser GNU Public License, Version 3</name>
            <url>http://www.gnu.org/licenses/lgpl-3.0.html</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>${project.build.sourceEncoding}</project.reporting.outputEncoding>

        <java.source.version>1.8</java.source.version>
        <java.target.version>${java.source.version}</java.target.version>
        <java.compiler.version>${java.source.version}</java.compiler.version>

        <!-- dependencies -->
        <testng.version>6.9.10</testng.version>

        <!-- plugins -->
        <coveralls-maven-plugin.version>4.3.0</coveralls-maven-plugin.version>
        <findbugs-maven-plugin.version>3.0.5</findbugs-maven-plugin.version>
        <jacoco-maven-plugin.version>0.8.4</jacoco-maven-plugin.version>

        <maven-clean-plugin.version>3.1.0</maven-clean-plugin.version>
        <maven-compiler-plugin.version>3.8.1</maven-compiler-plugin.version>
        <maven-deploy-plugin.version>3.0.0-M1</maven-deploy-plugin.version>
        <maven-gpg-plugin.version>1.6</maven-gpg-plugin.version>
        <maven-jar-plugin.version>3.1.2</maven-jar-plugin.version>
        <maven-javadoc-plugin.version>3.1.0</maven-javadoc-plugin.version>
        <maven-release-plugin.version>2.5.3</maven-release-plugin.version>
        <maven-resources-plugin.version>3.1.0</maven-resources-plugin.version>
        <maven-source-plugin.version>3.1.0</maven-source-plugin.version>

        <nexus-staging-maven-plugin.version>1.6.8</nexus-staging-maven-plugin.version>
    </properties>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <artifactId>maven-clean-plugin</artifactId>
                    <version>3.0.0</version>
                </plugin>

                <plugin>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>${maven-compiler-plugin.version}</version>
                    <configuration>
                        <source>${java.source.version}</source>
                        <target>${java.target.version}</target>
                        <encoding>${project.build.sourceEncoding}</encoding>
                        <showDeprecation>true</showDeprecation>
                        <compilerArgument>-Xlint:all</compilerArgument>
                    </configuration>
                </plugin>

                <plugin>
                    <artifactId>maven-deploy-plugin</artifactId>
                    <version>${maven-deploy-plugin.version}</version>
                </plugin>

                <plugin>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>${maven-source-plugin.version}</version>
                    <executions>
                        <execution>
                            <id>attach-sources</id>
                            <goals>
                                <goal>jar-no-fork</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>

                <plugin>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>${maven-javadoc-plugin.version}</version>
                    <executions>
                        <execution>
                            <id>attach-javadocs</id>
                            <goals>
                                <goal>jar</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>

                <plugin>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>${maven-release-plugin.version}</version>
                    <configuration>
                        <autoVersionSubmodules>true</autoVersionSubmodules>
                        <useReleaseProfile>false</useReleaseProfile>
                        <releaseProfiles>release</releaseProfiles>
                        <goals>deploy</goals>
                    </configuration>
                </plugin>

                <plugin>
                    <artifactId>maven-resources-plugin</artifactId>
                    <version>${maven-resources-plugin.version}</version>
                    <configuration>
                        <encoding>${project.build.sourceEncoding}</encoding>
                    </configuration>
                </plugin>

                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>findbugs-maven-plugin</artifactId>
                    <version>${findbugs-maven-plugin.version}</version>
                    <configuration>
                        <failOnError>false</failOnError>
                        <effort>Max</effort>
                        <xmlOutput>true</xmlOutput>
                    </configuration>
                    <executions>
                        <execution>
                            <phase>test-compile</phase>
                            <goals>
                                <goal>check</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>

                <plugin>
                    <groupId>org.jacoco</groupId>
                    <artifactId>jacoco-maven-plugin</artifactId>
                    <version>${jacoco-maven-plugin.version}</version>
                    <executions>
                        <execution>
                            <id>prepare-agent</id>
                            <goals>
                                <goal>prepare-agent</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>

                <plugin>
                    <groupId>org.eluder.coveralls</groupId>
                    <artifactId>coveralls-maven-plugin</artifactId>
                    <version>${coveralls-maven-plugin.version}</version>
                    <configuration>
                        <repoToken>${env.COVERALLS_TOKEN}</repoToken>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <artifactId>maven-deploy-plugin</artifactId>
            </plugin>
            <plugin>
                <artifactId>maven-clean-plugin</artifactId>
            </plugin>
            <plugin>
                <artifactId>maven-release-plugin</artifactId>
            </plugin>
        </plugins>
    </build>

    <organization>
        <name>TecSinapse</name>
        <url>http://www.tecsinapse.com.br</url>
    </organization>

    <developers>
        <developer>
            <id>tecsinapse</id>
            <name>TecSinapse</name>
            <email>dev@tecsinapse.com.br</email>
            <organization>${project.organization.name}</organization>
            <organizationUrl>${project.organization.url}</organizationUrl>
        </developer>
    </developers>

    <distributionManagement>
        <snapshotRepository>
            <id>sonatype-nexus</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>sonatype-nexus</id>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
    </distributionManagement>

    <scm>
        <url>https://github.com/tecsinapse/tecsinapse-oss-parent</url>
        <connection>scm:git:git@github.com:tecsinapse/tecsinapse-oss-parent.git</connection>
        <developerConnection>scm:git:git@github.com:tecsinapse/tecsinapse-oss-parent.git</developerConnection>
        <tag>tecsinapse-oss-parent-2.0.2</tag>
    </scm>

    <issueManagement>
        <system>GitHub</system>
        <url>https://github.com/tecsinapse/tecsinapse-oss-parent/issues</url>
    </issueManagement>

    <ciManagement>
        <system>Travis CI</system>
        <url>https://travis-ci.org/tecsinapse/tecsinapse-oss-parent</url>
    </ciManagement>

    <dependencyManagement>
        <dependencies>
            <!-- test -->
            <dependency>
                <groupId>org.testng</groupId>
                <artifactId>testng</artifactId>
                <version>${testng.version}</version>
                <scope>test</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <profiles>
        <profile>
            <id>sonatype-nexus</id>
            <properties>
                <gpg.executable>gpg</gpg.executable>
                <gpg.defaultKeyring>false</gpg.defaultKeyring>
                <gpg.keyname>${env.GPG_KEYNAME}</gpg.keyname>
                <gpg.passphrase>${env.GPG_PASSPHRASE}</gpg.passphrase>
                <gpg.publicKeyring>${env.GPG_DIR}/pubring.gpg</gpg.publicKeyring>
                <gpg.secretKeyring>${env.GPG_DIR}/secring.gpg</gpg.secretKeyring>
            </properties>
            <activation>
                <property>
                    <name>performRelease</name>
                    <value>true</value>
                </property>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>${maven-gpg-plugin.version}</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <version>${nexus-staging-maven-plugin.version}</version>
                        <extensions>true</extensions>
                        <configuration>
                            <serverId>sonatype-nexus</serverId>
                            <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <prerequisites>
        <maven>3.3.9</maven>
    </prerequisites>

</project>
