<?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">
   <name>Commons</name>
   <description>A minimal library for common functions including identity generation, JSON parsing and reflection.</description>
   <url>https://github.com/PatternFM/commons</url>

   <groupId>fm.pattern</groupId>
   <artifactId>commons</artifactId>
   <version>1.0.9</version>
   <modelVersion>4.0.0</modelVersion>
   <packaging>pom</packaging>

   <properties>
      <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
      <jersey.version>2.14</jersey.version>
      <java.version>1.8</java.version>
      <maven.compiler.source>1.8</maven.compiler.source>
      <maven.compiler.target>1.8</maven.compiler.target>
   </properties>

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

   <developers>
      <developer>
         <id>brandon.john.grenier</id>
         <name>Brandon Grenier</name>
      </developer>
   </developers>

   <scm>
      <developerConnection>scm:git:https://github.com/PatternFM/commons.git</developerConnection>
      <url>scm:git:https://github.com/PatternFM/commons.git</url>
      <tag>commons-1.0.9</tag>
   </scm>

   <distributionManagement>
      <repository>
         <id>ossrh</id>
         <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
      </repository>

      <snapshotRepository>
         <id>pattern-snapshot-repo</id>
         <name>Pattern Snapshot Repository</name>
         <url>s3://repository.pattern.fm/snapshots</url>
      </snapshotRepository>
   </distributionManagement>

   <modules>
      <module>commons-util</module>
   </modules>

   <repositories>
      <repository>
         <id>pattern-snapshot-repo</id>
         <name>Pattern Snapshot Repository</name>
         <url>http://repository.pattern.fm/snapshots</url>
      </repository>
   </repositories>

   <pluginRepositories>
      <pluginRepository>
         <id>spring-maven-release</id>
         <name>Spring Maven Release Repository</name>
         <url>http://maven.springframework.org/release</url>
      </pluginRepository>
   </pluginRepositories>

   <profiles>
      <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-gpg-plugin</artifactId>
                  <version>1.5</version>
                  <executions>
                     <execution>
                        <id>sign-artifacts</id>
                        <phase>verify</phase>
                        <goals>
                           <goal>sign</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.sonatype.plugins</groupId>
                  <artifactId>nexus-staging-maven-plugin</artifactId>
                  <version>1.6.3</version>
                  <extensions>true</extensions>
                  <configuration>
                     <serverId>ossrh</serverId>
                     <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                     <autoReleaseAfterClose>true</autoReleaseAfterClose>
                  </configuration>
               </plugin>
            </plugins>
         </build>
      </profile>
   </profiles>

   <build>
      <extensions>
         <extension>
            <groupId>org.springframework.build</groupId>
            <artifactId>aws-maven</artifactId>
            <version>5.0.0.RELEASE</version>
         </extension>

         <extension>
            <groupId>org.kuali.maven.wagons</groupId>
            <artifactId>maven-s3-wagon</artifactId>
            <version>1.2.1</version>
         </extension>
      </extensions>

      <plugins>
         <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-release-plugin</artifactId>
            <version>2.5.1</version>
            <configuration>
               <goals>deploy</goals>
               <autoversionsubmodules>true</autoversionsubmodules>
               <tagNameFormat>commons-@{project.version}</tagNameFormat>
            </configuration>
            <dependencies>
               <dependency>
                  <groupId>org.apache.maven.plugins</groupId>
                  <artifactId>maven-scm-plugin</artifactId>
                  <version>1.8.1</version>
               </dependency>
            </dependencies>
         </plugin>

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

         <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.1</version>
            <configuration>
               <source>${java.version}</source>
               <target>${java.version}</target>
            </configuration>
         </plugin>
      </plugins>
   </build>
</project>
