<?xml version="1.0" encoding="ISO-8859-1"?>

<!--
  Copyright 2019, California Institute of Technology ("Caltech").
  U.S. Government sponsorship acknowledged.
 
  All rights reserved.
 
  Redistribution and use in source and binary forms, with or without
  modification, are permitted provided that the following conditions are met:
 
  * Redistributions of source code must retain the above copyright notice,
  this list of conditions and the following disclaimer.
  * Redistributions must reproduce the above copyright notice, this list of
  conditions and the following disclaimer in the documentation and/or other
  materials provided with the distribution.
  * Neither the name of Caltech nor its operating division, the Jet Propulsion
  Laboratory, nor the names of its contributors may be used to endorse or
  promote products derived from this software without specific prior written
  permission.
 
  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
  LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  POSSIBILITY OF SUCH DAMAGE.
-->

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

  <groupId>gov.nasa.pds</groupId>
  <artifactId>pds3-product-tools</artifactId>
  <version>4.0.1</version>
  <packaging>jar</packaging>

  <name>${project.groupId}:${project.artifactId}</name>
  <description>
    The PDS3 Product Tools Library project supports design/generation, validation and submission of archival products to the PDS. This project consists of a library of software classes to support the development of tools to perform these functions and is designed to be utilized by developers from the Engineering Node, Discipline Nodes and the PDS community.
  </description>
  <url>https://github.com/NASA-PDS-Incubator/pds3-product-tools</url>

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

  <developers>
    <developer>
      <name>Jordan Padams</name>
      <id>jpadams</id>
      <email>Jordan.H.Padams@jpl.nasa.gov</email>
      <organization>NASA Jet Propulsion Laboratory</organization>
      <roles>
        <role>PDS Engineering Node Manager</role>
      </roles>
    </developer>
    <developer>
      <name>Galen Hollins</name>
      <id>ghollins</id>
      <email>Galen.Hollins@jpl.nasa.gov</email>
      <organization>NASA Jet Propulsion Laboratory</organization>
      <roles>
        <role>PDS Engineering Node Development Lead</role>
      </roles>
    </developer>
    <developer>
      <name>Sean Hardman</name>
      <id>shardman</id>
      <email>Sean.Hardman@jpl.nasa.gov</email>
      <organization>NASA Jet Propulsion Laboratory</organization>
      <roles>
        <role>Former Development Lead</role>
      </roles>
    </developer>
    <developer>
      <name>Michael Cayanan</name>
      <id>mcayanan</id>
      <email>Michael.Cayanan@jpl.nasa.gov</email>
      <organization>NASA Jet Propulsion Laboratory</organization>
      <roles>
        <role>Former Developer</role>
      </roles>
    </developer>
    <developer>
      <name>Paul Ramirez</name>
      <id>pramirez</id>
      <email>Paul.Ramirez@jpl.nasa.gov</email>
      <organization>NASA Jet Propulsion Laboratory</organization>
      <roles>
        <role>Former Developer</role>
      </roles>
    </developer>
    <developer>
      <name>Joshua Ganderson</name>
      <id>jagander</id>
      <organization>NASA Ames Research Center</organization>
      <roles>
        <role>Former Developer</role>
      </roles>
    </developer>
  </developers>

  <contributors>
    <contributor>
      <name>Steve Hughes</name>
      <email>Steve.Hughes@jpl.nasa.gov</email>
      <organization>NASA Jet Propulsion Laboratory</organization>
      <roles>
        <role>System Engineer</role>
      </roles>
    </contributor>
    <contributor>
      <name>Ron Joyner</name>
      <email>Ron.Joyner@jpl.nasa.gov</email>
      <organization>NASA Jet Propulsion Laboratory</organization>
      <roles>
        <role>System Engineer</role>
      </roles>
    </contributor>
    <contributor>
      <name>Elizabeth Rye</name>
      <email>Elizabeth.Rye@jpl.nasa.gov</email>
      <organization>NASA Jet Propulsion Laboratory</organization>
      <roles>
        <role>System Engineer</role>
      </roles>
    </contributor>
    <contributor>
      <name>Mark Rose</name>
      <email>Mark.Rose@nasa.gov</email>
      <organization>NASA Ames Research Center</organization>
      <roles>
        <role>Consultant</role>
      </roles>
    </contributor>
  </contributors>

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

  <build>
    <testSourceDirectory>src/test</testSourceDirectory>
    <resources>
      <resource>
        <filtering>true</filtering>
        <targetPath>gov/nasa/pds/tools/util</targetPath>
        <directory>src/main/resources/conf</directory>
        <includes>
          <include>product-tools.properties</include>
        </includes>
      </resource>
      <resource>
        <directory>${basedir}/src/main/java</directory>
      </resource>
    </resources>
    <plugins>
      <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>
      <plugin>
	<groupId>org.apache.maven.plugins</groupId>
	<artifactId>maven-site-plugin</artifactId>
	<version>3.7.1</version>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
	    <version>3.0.0</version>
        <configuration>
          <archive>
            <manifest>
              <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
            </manifest>
          </archive>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>buildnumber-maven-plugin</artifactId>
        <executions>
          <execution>
            <phase>validate</phase>
            <goals>
              <goal>create</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
	  <revisionOnScmFailure>unknownbuild</revisionOnScmFailure>
          <format>{0,date,yyyy-MM-dd HH:mm:ss}</format>
          <items>
            <item>timestamp</item>
          </items>
          <doCheck>false</doCheck>
          <doUpdate>false</doUpdate>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-antrun-plugin</artifactId>
        <dependencies>
          <dependency>
            <groupId>ant</groupId>
            <artifactId>ant-nodeps</artifactId>
            <version>1.6.5</version>
          </dependency>
          <dependency>
            <groupId>jakarta-regexp</groupId>
            <artifactId>jakarta-regexp</artifactId>
            <version>1.4</version>
          </dependency>
          <dependency>
            <groupId>ant</groupId>
            <artifactId>ant-jakarta-regexp</artifactId>
            <version>1.6.1</version>
          </dependency>
        </dependencies>
        <executions>
          <execution>
            <id>build_parser</id>
            <phase>generate-sources</phase>
            <configuration>
              <tasks>
                <ant antfile="build.xml" target="build-parser" />
              </tasks>
              <sourceRoot>${project.build.directory}/generated-sources/antlr3</sourceRoot>              
            </configuration>
            <goals>
              <goal>run</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-assembly-plugin</artifactId>
        <executions>
          <execution>
            <id>bin-release</id>
            <phase>package</phase>
            <goals>
              <goal>single</goal>
            </goals>
            <configuration>
              <descriptors>
                <descriptor>src/main/assembly/tar-assembly.xml</descriptor>
                <descriptor>src/main/assembly/zip-assembly.xml</descriptor>
              </descriptors>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <source>1.8</source>
          <target>1.8</target>
        </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>

  <scm>
    <url>https://github.com/NASA-PDS-Incubator/pds3-product-tools/tree/master</url>
    <connection>scm:git:git://github.com/NASA-PDS-Incubator/pds3-product-tools.git</connection>
    <developerConnection>scm:git:ssh://github.com:NASA-PDS-Incubator/pds3-product-tools.git</developerConnection>
  </scm>
  
  <profiles>
    <profile> 
      <id>release</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <executions>
              <execution>
                <id>attach-sources</id>
                <phase>prepare-package</phase>
                <goals>
                  <goal>jar-no-fork</goal>
                  <goal>test-jar</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
    		<configuration>
              <source>1.8</source>
    	  	  <failOnError>false</failOnError>
            </configuration>
            <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>
                    <configuration>
                        <gpgArguments>
                            <arg>--pinentry-mode</arg>
                            <arg>loopback</arg>
                        </gpgArguments>
                    </configuration>
                </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

  <dependencies>
    <dependency>
      <groupId>commons-cli</groupId>
      <artifactId>commons-cli</artifactId>
      <version>1.2</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>commons-io</groupId>
      <artifactId>commons-io</artifactId>
      <version>1.4</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>commons-lang</groupId>
      <artifactId>commons-lang</artifactId>
      <version>2.4</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>log4j</groupId>
      <artifactId>log4j</artifactId>
      <version>1.2.12</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>org.antlr</groupId>
      <artifactId>antlr</artifactId>
      <version>3.2</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>org.incava</groupId>
      <artifactId>java-diff</artifactId>
      <version>1.1</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.0</version>
      <scope>test</scope>
      <optional>true</optional>
    </dependency>
  </dependencies>

  <reporting>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-project-info-reports-plugin</artifactId>
        <reportSets>
          <reportSet>
            <reports>
              <report>dependencies</report>
              <report>issue-management</report>
              <report>licenses</report>
              <report>mailing-lists</report>
              <report>team</report>
              <report>summary</report>
            </reports>
          </reportSet>
        </reportSets>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-changes-plugin</artifactId>
        <reportSets>
          <reportSet>
            <reports>
              <report>changes-report</report>
            </reports>
          </reportSet>
        </reportSets>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
		<configuration>
          <source>1.8</source>
	  	  <failOnError>false</failOnError>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-report-plugin</artifactId>
      </plugin>
    </plugins>
  </reporting>
</project>
