<?xml version="1.0" encoding="UTF-8"?>
<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>eu.stamp-project</groupId>
    <artifactId>descartes</artifactId>
    <version>1.0</version>
    <packaging>jar</packaging>

    <!-- Name must match artifactId so PIT can find the plugin -->
    <!--<name>${project.groupId}:${project.artifactId}</name>-->

    <name>${project.groupId}:${project.artifactId}</name>
    <description>Mutation engine for PITest implementing extreme mutation operators</description>
    <url>https://github.com/STAMP-project/pitest-descartes.git</url>

    <organization>
        <!--
            Can't use the real name until the leap to 1.2.1 could be made.
            In 1.2.1 the MutationEngineFactory interface have important changes.
         -->
        <!--<name>STAMP-Project</name>-->
        <name>eu.stamp-project</name>
        <url>http://github.com/STAMP-project</url>
    </organization>

    <licenses>
        <license>
            <name>GNU Lesser General Public License v3.0</name>
            <url>https://github.com/STAMP-project/pitest-descartes/blob/master/LICENSE</url>
        </license>
    </licenses>

    <issueManagement>
        <system>GitHub</system>
        <url>https://github.com/STAMP-project/pitest-descartes/issues</url>
    </issueManagement>

    <developers>
        <developer>
            <name>Oscar Luis Vera Pérez</name>
            <email>oscar.vera-perez@inria.fr</email>
        </developer>
    </developers>

    <scm>
        <connection>scm:git:git://github.com:STAMP-project/pitest-descartes.git</connection>
        <developerConnection>scm:git:git@github.com:STAMP-project/pitest-descartes.git</developerConnection>
        <url>https://github.com/STAMP-project/pitest-descartes</url>
        <tag>descartes-1.0</tag>
    </scm>

    <repositories>
        <repository>
            <id>stamp-maven-repository-mvn-repo</id>
            <url>https://stamp-project.github.io/stamp-maven-repository/</url>
            <snapshots>
                <enabled>true</enabled>
                <updatePolicy>always</updatePolicy>
            </snapshots>
        </repository>
        <repository>
            <id>gradle-repo</id>
            <name>Gradle Tooling API repository</name>
            <url>https://repo.gradle.org/gradle/libs-releases-local/</url>
        </repository>
    </repositories>

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

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <github.global.server>github</github.global.server>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.pitest</groupId>
            <artifactId>pitest</artifactId>
            <version>1.2.0</version>
        </dependency>

        <dependency>
            <groupId>org.pitest</groupId>
            <artifactId>pitest-entry</artifactId>
            <version>1.2.0</version>
        </dependency>

        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.12</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.hamcrest</groupId>
            <artifactId>hamcrest-all</artifactId>
            <version>1.3</version>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <build>
        <plugins>

            <!-- Generate code from jFlex files -->
            <plugin>
                <groupId>de.jflex</groupId>
                <artifactId>jflex-maven-plugin</artifactId>
                <version>1.6.1</version>
                <executions>
                    <execution>
                        <goals><goal>generate</goal></goals>
                        <configuration>
                            <outputDirectory>target/generated-sources/jflex</outputDirectory>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

            <!-- Source code version -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.7.0</version>
                <configuration>
                    <source>1.8</source>
                    <target>1.8</target>
                </configuration>
            </plugin>

            <!-- Testing reporting and coverage -->
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
                <version>0.7.6.201602180812</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>4.3.0</version>
            </plugin>


            <!-- Include metadata in manifest file -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>2.6</version>
                <configuration>
                    <archive>
                        <manifest>
                            <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                            <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
                        </manifest>
                    </archive>
                </configuration>
            </plugin>


            <!-- To deploy on Maven Central -->

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-deploy-plugin</artifactId>
                <version>2.8.1</version>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>2.5.3</version>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.0.0-M1</version>
            </plugin>

            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
                <version>1.6.8</version>
                <extensions>true</extensions>
                <configuration>
                    <serverId>ossrh</serverId>
                    <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                    <autoReleaseAfterClose>true</autoReleaseAfterClose>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>org.apache.maven.wagon</groupId>
                        <artifactId>wagon-ssh</artifactId>
                        <version>2.12</version>
                    </dependency>
                </dependencies>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-gpg-plugin</artifactId>
                <version>1.6</version>
                <executions>
                    <execution>
                        <id>sign-artifacts</id>
                        <phase>verify</phase>
                        <goals>
                            <goal>sign</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <artifactId>maven-assembly-plugin</artifactId>
                <configuration>
                    <descriptorRefs>
                        <descriptorRef>jar-with-dependencies</descriptorRef>
                    </descriptorRefs>
                </configuration>
                <executions>
                    <execution>
                        <id>make-my-jar-with-dependencies</id>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

</project>
