<?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/maven-v4_0_0.xsd">

  <modelVersion>4.0.0</modelVersion>
  <artifactId>gedcomx-parent</artifactId>
  <groupId>org.gedcomx</groupId>
  <name>GEDCOM X - Parent Project</name>
  <description>The Java implementation of the GEDCOM X specification set.</description>
  <url>https://github.com/FamilySearch/gedcomx-java</url>
  <version>2.144.0</version>
  <packaging>pom</packaging>

  <properties>
    <!-- Various settings -->
    <java.compiler.version>1.8</java.compiler.version>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <root.basedir>${project.basedir}</root.basedir>
    <skip.javadoc>true</skip.javadoc>
    <skip.pgp>true</skip.pgp>

    <!-- Dependency versions -->
    <assertj.version>3.16.1</assertj.version>
    <commons-codec.version>1.10</commons-codec.version>
    <enunciate.version>2.7.0</enunciate.version>
    <hamcrest.version>2.2</hamcrest.version>
    <handy-uri.version>2.1.6</handy-uri.version>
    <jackson.databind.version>2.10.0</jackson.databind.version>
    <jackson.jaxrs.version>2.10.0</jackson.jaxrs.version>
    <glassfish-jaxb-runtime.version>2.3.3</glassfish-jaxb-runtime.version>
    <jersey1.version>1.19.4</jersey1.version>
    <jena-arq.version>3.17.0</jena-arq.version>
    <jsr311-api.version>1.1.1</jsr311-api.version>
    <junit.version>4.13.1</junit.version>
    <junit-jupiter.version>5.6.2</junit-jupiter.version>
    <junit-platform.version>1.6.2</junit-platform.version>

    <mockito.version>1.10.19</mockito.version>
    <woodstox-core.version>5.0.3</woodstox-core.version>

    <!-- Plugin versions -->
    <maven-compiler-plugin.version>3.5.1</maven-compiler-plugin.version>
    <maven-javadoc-plugin.version>2.10.4</maven-javadoc-plugin.version>
    <maven-license-plugin.version>1.4.0</maven-license-plugin.version>
    <maven-release-plugin-plugin.version>2.5.3</maven-release-plugin-plugin.version>
    <maven-resources-plugin.version>3.0.1</maven-resources-plugin.version>
    <maven-source-plugin.version>3.0.1</maven-source-plugin.version>
    <maven-surefire-plugin.version>2.19.1</maven-surefire-plugin.version>
    <nexus-staging-maven-plugin.version>1.6.7</nexus-staging-maven-plugin.version>
    <pgp-maven-plugin.version>1.1</pgp-maven-plugin.version>
  </properties>

  <modules>
    <!--utility modules-->
    <module>gedcomx-rt-support</module>
    <module>gedcomx-test-support</module>

    <!--gedcomx-core modules-->
    <module>gedcomx-date</module>
    <module>gedcomx-model</module>
    <module>gedcomx-fileformat</module>

    <!--gedcomx-rs modules-->
    <module>gedcomx-atom</module>
    <module>gedcomx-rs-rt-support</module>
    <module>gedcomx-rs-client</module>

    <!--extension modules-->
    <module>extensions/familysearch</module>

  </modules>

  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.assertj</groupId>
      <artifactId>assertj-core</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.platform</groupId>
      <artifactId>junit-platform-launcher</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.hamcrest</groupId>
      <artifactId>hamcrest-core</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.hamcrest</groupId>
      <artifactId>hamcrest-library</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-core</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <scm>
    <connection>scm:git:git@github.com:FamilySearch/gedcomx-java.git</connection>
    <developerConnection>scm:git:git@github.com:FamilySearch/gedcomx-java.git</developerConnection>
    <url>https://github.com/FamilySearch/gedcomx-java</url>
    <tag>2.144.0</tag>
  </scm>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>com.webcohesion.enunciate</groupId>
        <artifactId>enunciate-core-annotations</artifactId>
        <version>${enunciate.version}</version>
      </dependency>

      <dependency>
        <groupId>com.fasterxml.jackson.core</groupId>
        <artifactId>jackson-databind</artifactId>
        <version>${jackson.databind.version}</version>
      </dependency>

      <dependency>
        <groupId>com.fasterxml.jackson.jaxrs</groupId>
        <artifactId>jackson-jaxrs-json-provider</artifactId>
        <version>${jackson.jaxrs.version}</version>
      </dependency>

      <dependency>
        <groupId>com.fasterxml.woodstox</groupId>
        <artifactId>woodstox-core</artifactId>
        <version>${woodstox-core.version}</version>
      </dependency>

      <dependency>
        <groupId>org.glassfish.jaxb</groupId>
        <artifactId>jaxb-runtime</artifactId>
        <version>${glassfish-jaxb-runtime.version}</version>
      </dependency>

      <dependency>
        <groupId>javax.ws.rs</groupId>
        <artifactId>jsr311-api</artifactId>
        <version>${jsr311-api.version}</version>
      </dependency>

      <dependency>
        <groupId>commons-codec</groupId>
        <artifactId>commons-codec</artifactId>
        <version>${commons-codec.version}</version>
      </dependency>

      <dependency>
        <groupId>com.sun.jersey</groupId>
        <artifactId>jersey-client</artifactId>
        <version>${jersey1.version}</version>
      </dependency>

      <dependency>
        <groupId>com.sun.jersey</groupId>
        <artifactId>jersey-server</artifactId>
        <version>${jersey1.version}</version>
        <scope>provided</scope>
      </dependency>

      <dependency>
        <groupId>com.sun.jersey.contribs</groupId>
        <artifactId>jersey-multipart</artifactId>
        <version>${jersey1.version}</version>
      </dependency>

      <dependency>
        <groupId>com.damnhandy</groupId>
        <artifactId>handy-uri-templates</artifactId>
        <version>${handy-uri.version}</version>
      </dependency>

      <dependency>
        <groupId>org.apache.jena</groupId>
        <artifactId>jena-arq</artifactId>
        <version>${jena-arq.version}</version>
      </dependency>

      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>${junit.version}</version>
      </dependency>
      <dependency>
        <groupId>org.junit.jupiter</groupId>
        <artifactId>junit-jupiter</artifactId>
        <version>${junit-jupiter.version}</version>
      </dependency>
      <dependency>
        <groupId>org.assertj</groupId>
        <artifactId>assertj-core</artifactId>
        <version>${assertj.version}</version>
      </dependency>
      <dependency>
        <groupId>org.junit.platform</groupId>
        <artifactId>junit-platform-launcher</artifactId>
        <version>${junit-platform.version}</version>
      </dependency>
      <dependency>
        <groupId>org.hamcrest</groupId>
        <artifactId>hamcrest-core</artifactId>
        <version>${hamcrest.version}</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.hamcrest</groupId>
        <artifactId>hamcrest-library</artifactId>
        <version>${hamcrest.version}</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.mockito</groupId>
        <artifactId>mockito-core</artifactId>
        <version>${mockito.version}</version>
      </dependency>

    </dependencies>
  </dependencyManagement>

 <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <encoding>${project.build.sourceEncoding}</encoding>
          <source>${java.compiler.version}</source>
          <target>${java.compiler.version}</target>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
          <configuration>
          	<parallel>classes</parallel>
          	<useUnlimitedThreads>true</useUnlimitedThreads>
          </configuration>

      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <executions>
          <execution>
            <id>attach-sources</id>
            <phase>package</phase>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-resources-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>com.google.code.maven-license-plugin</groupId>
        <artifactId>maven-license-plugin</artifactId>
        <configuration>
          <header>${root.basedir}/LICENSE-header.txt</header>
          <includes>
            <include>src/main/java/**</include>
          </includes>
          <properties>
            <copyright.year>${inceptionYear}</copyright.year>
          </properties>
        </configuration>
        <executions>
          <execution>
            <phase>validate</phase>
            <goals>
              <goal>check</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.sonatype.plugins</groupId>
        <artifactId>nexus-staging-maven-plugin</artifactId>
        <extensions>true</extensions>
        <configuration>
          <serverId>ossrh</serverId>
          <nexusUrl>https://oss.sonatype.org/</nexusUrl>
          <autoReleaseAfterClose>true</autoReleaseAfterClose>
          <!-- 05/15/2019 getting a timeout error closing staging repository at oss.sonatype.org  It seemed to be working, just slow.  default is 5 min -->
          <stagingProgressTimeoutMinutes>10</stagingProgressTimeoutMinutes>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-release-plugin</artifactId>
        <configuration>
          <autoVersionSubmodules>true</autoVersionSubmodules>
          <useReleaseProfile>false</useReleaseProfile>
          <releaseProfiles>release</releaseProfiles>
          <goals>deploy</goals>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <executions>
          <execution>
            <id>attach-javadocs</id>
            <goals>
              <goal>jar</goal>
            </goals>
            <configuration>
              <skip>${skip.javadoc}</skip>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.kohsuke</groupId>
        <artifactId>pgp-maven-plugin</artifactId>
        <executions>
          <execution>
            <id>sign-artifacts</id>
            <phase>verify</phase>
            <goals>
              <goal>sign</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <skip>${skip.pgp}</skip>
          <secretkey>keyfile:${env.PGP_SECRET_KEYFILE}</secretkey>
          <passphrase>literal:</passphrase>
        </configuration>
      </plugin>
    </plugins>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>${maven-compiler-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>${maven-surefire-plugin.version}</version>
          <configuration>
          	<parallel>classes</parallel>
          	<useUnlimitedThreads>true</useUnlimitedThreads>
          </configuration>

        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-source-plugin</artifactId>
          <version>${maven-source-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-resources-plugin</artifactId>
          <version>${maven-resources-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>com.google.code.maven-license-plugin</groupId>
          <artifactId>maven-license-plugin</artifactId>
          <version>${maven-license-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>org.sonatype.plugins</groupId>
          <artifactId>nexus-staging-maven-plugin</artifactId>
          <version>${nexus-staging-maven-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-release-plugin</artifactId>
          <version>${maven-release-plugin-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>${maven-javadoc-plugin.version}</version>
        </plugin>
        <plugin>
          <groupId>org.kohsuke</groupId>
          <artifactId>pgp-maven-plugin</artifactId>
          <version>${pgp-maven-plugin.version}</version>
        </plugin>
      </plugins>
    </pluginManagement>
  </build>

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

  <developers>
    <developer>
      <name>Ryan Heaton</name>
      <url>https://github.com/stoicflame</url>
    </developer>
    <developer>
      <name>Todd Chapman</name>
      <url>https://github.com/wahkara</url>
    </developer>
    <developer>
      <name>Erik Wilford</name>
      <url>https://github.com/wilfordej</url>
    </developer>
    <developer>
      <name>David Nash</name>
      <url>https://github.com/dnash21e</url>
    </developer>
    <developer>
      <name>Randy Wilson</name>
      <url>https://github.com/ranbo</url>
    </developer>
  </developers>

  <profiles>
    <profile>
      <id>release</id>
      <properties>
        <skip.javadoc>false</skip.javadoc>
        <skip.pgp>false</skip.pgp>
      </properties>
    </profile>
  </profiles>

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