<?xml version="1.0"?>
<!--
  ~ Copyright (c) 2016 chibchasoft.com
  ~
  ~ All rights reserved. This program and the accompanying materials
  ~ are made available under the terms of the Apache License v2.0 which accompanies
  ~ this distribution.
  ~
  ~      The Apache License v2.0 is available at
  ~      https://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Author <a href="mailto:jvelez@chibchasoft.com">Juan Velez</a>
  -->

<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>com.chibchasoft</groupId>
  <artifactId>vertx-dependent-verticle-deployer</artifactId>
  <version>1.0.1</version>

  <name>Vert.x Dependent Verticle Deployer</name>
  <description>A Vert.x Verticle intended to deploy verticles that depend on other verticles</description>
  <url>https://github.com/juanavelez/vertx-dependent-verticle-deployer</url>

  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0</url>
      <distribution>repo</distribution>
    </license>
  </licenses>

  <developers>
    <developer>
      <name>Juan Velez</name>
      <email>jvelez@chibchasoft.com</email>
      <url>https://github.com/juanavelez/vertx-dependent-verticle-deployer</url>
    </developer>
  </developers>

  <scm>
    <connection>scm:git:git://github.com/juanavelez/vertx-dependent-verticle-deployer.git</connection>
    <developerConnection>scm:git:git://github.com/juanavelez/vertx-dependent-verticle-deployer.git</developerConnection>
    <url>https://github.com/juanavelez/vertx-dependent-verticle-deployerr</url>
  </scm>

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

  <properties>
    <junit.version>4.12</junit.version>
    <log4j2.version>2.6.2</log4j2.version>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>
    <maven.javadoc.plugin.version>2.10.1</maven.javadoc.plugin.version>
    <maven.source.plugin.version>2.4</maven.source.plugin.version>
    <vertx.core.version>3.3.3</vertx.core.version>
    <slf4j.version>1.7.21</slf4j.version>
  </properties>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <executions>
          <execution>
            <id>attach-sources</id>
            <goals>
              <goal>jar</goal>
              <goal>test-jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-javadoc-plugin</artifactId>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <systemProperties>
            <property>
              <name>log4j.configurationFile</name>
              <value>src/test/resources/log4j2-test.xml</value>
            </property>
          </systemProperties>
        </configuration>
      </plugin>
    </plugins>
  </build>

  <dependencies>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-core</artifactId>
      <version>${vertx.core.version}</version>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <version>${slf4j.version}</version>
      <scope>provided</scope>
    </dependency>

    <!-- Testing -->
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>${junit.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-core</artifactId>
      <version>${vertx.core.version}</version>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.apache.logging.log4j</groupId>
      <artifactId>log4j-slf4j-impl</artifactId>
      <version>${log4j2.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.apache.logging.log4j</groupId>
      <artifactId>log4j-api</artifactId>
      <version>${log4j2.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.apache.logging.log4j</groupId>
      <artifactId>log4j-core</artifactId>
      <version>${log4j2.version}</version>
      <scope>test</scope>
    </dependency>
  </dependencies>
  
  <profiles>
    <profile>
      <id>release</id>
      <activation>
        <property>
          <name>release</name>
        </property>
      </activation>
      <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>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
