<?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>io.wizzie</groupId>
    <artifactId>normalizer</artifactId>
    <version>0.6.1.2</version>

    <packaging>pom</packaging>

    <name>Wizzie normalizer</name>
    <description>The normalizer project</description>
    <url>https://github.com/wizzie-io/normalizer</url>

    <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>Wizzie Commiters</name>
            <email>devel@wizzie.io</email>
            <organization>Wizzie Analytics</organization>
            <organizationUrl>https://wizzie.io</organizationUrl>
        </developer>
    </developers>

    <inceptionYear>2017</inceptionYear>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</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>

    <scm>
        <developerConnection>scm:git:git@github.com:wizzie-io/normalizer.git</developerConnection>
        <connection>scm:git:git@github.com:wizzie-io/normalizer.git</connection>
        <tag>normalizer-0.6.1.2</tag>
        <url>git@github.com:wizzie-io/normalizer.git</url>
    </scm>

    <properties>
        <dropwizard.version>4.0.3</dropwizard.version>
        <joda.version>2.9.4</joda.version>
        <precondition.version>0.1.5</precondition.version>
        <jackson-jq.version>0.0.5</jackson-jq.version>
        <parsii.version>1.5</parsii.version>
        <kafka.version>1.1.0</kafka.version>
        <metrics-library.version>0.0.5</metrics-library.version>
        <config-bootstrapper.version>0.0.7</config-bootstrapper.version>
    </properties>

    <modules>
        <module>base</module>
        <module>model</module>
        <module>service</module>
        <module>functions</module>
    </modules>

    <profiles>
        <profile>
            <id>dist</id>
            <modules>
                <!-- distribution packaging -->
                <module>distribution</module>
            </modules>
        </profile>

        <profile>
            <id>docker</id>
            <modules>
                <!-- docker packaging -->
                <module>distribution</module>
                <module>docker</module>
            </modules>
        </profile>

        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>2.2.1</version>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>2.9.1</version>
                        <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>
                        <version>1.5</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <build>

        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>2.5.3</version>
                <configuration>
                    <autoVersionSubmodules>true</autoVersionSubmodules>
                    <useReleaseProfile>false</useReleaseProfile>
                    <releaseProfiles>release</releaseProfiles>
                    <goals>deploy</goals>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>2.19.1</version>
                <configuration>
                    <reuseForks>false</reuseForks>
                    <forkCount>1</forkCount>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
                <version>1.6.7</version>
                <extensions>true</extensions>
                <configuration>
                    <serverId>ossrh</serverId>
                    <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                    <autoReleaseAfterClose>true</autoReleaseAfterClose>
                </configuration>
            </plugin>
        </plugins>
    </build>

</project>