<!--

    This file is part of the CRISTAL-iSE REST API.
    Copyright (c) 2001-2016 The CRISTAL Consortium. All rights reserved.

    This library is free software; you can redistribute it and/or modify it
    under the terms of the GNU Lesser General Public License as published
    by the Free Software Foundation; either version 3 of the License, or (at
    your option) any later version.

    This library is distributed in the hope that it will be useful, but WITHOUT
    ANY WARRANTY; with out even the implied warranty of MERCHANTABILITY or
    FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
    License for more details.

    You should have received a copy of the GNU Lesser General Public License
    along with this library; if not, write to the Free Software Foundation,
    Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.

    http://www.fsf.org/licensing/licenses/lgpl.html

-->
<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>
    <name>CRISTAL-iSE Restapi</name>
    <groupId>org.cristalise</groupId>
    <artifactId>cristalise-restapi</artifactId>
    <packaging>jar</packaging>
    <version>3.3.0</version>
    <description>CRISTAL-iSE REST API Module</description>
    <url>https://github.com/cristal-ise/xpath-outcomeinit</url>
    <licenses>
        <license>
            <name>GNU Library or Lesser General Public License v3 (LGPL3)</name>
            <url>http://www.gnu.org/licenses/lgpl.html</url>
        </license>
    </licenses>
    <developers>
        <developer>
            <name>Zsolt Kovács</name>
            <email>zs.myth@gmail.com</email>
            <organization>cristal-ise on github</organization>
            <organizationUrl>https://github.com/cristal-ise</organizationUrl>
            <roles>
                <role>Pinky/Brain/CTO</role>
            </roles>
        </developer>
    </developers>
    <issueManagement>
        <url>https://github.com/cristal-ise/restapi/issues</url>
        <system>GitHub</system>
    </issueManagement>
    <organization>
        <name>CRISTAL-iSE</name>
        <url>http://cristal-ise.github.io/</url>
    </organization>
    <ciManagement>
        <system>Travis</system>
        <url>https://travis-ci.org/cristal-ise/restapi</url>
    </ciManagement>
    <scm>
        <developerConnection>scm:https://github.com/cristal-ise/restapi.git</developerConnection>
        <url>https://github.com/cristal-ise/restapi</url>
        <tag>master</tag>
    </scm>
    <mailingLists>
        <mailingList>
            <name>User List</name>
            <post>cristal-users@cern.ch</post>
            <subscribe>cristal-users-subscribe@cern.ch</subscribe>
            <unsubscribe>cristal-users-unsubscribe@cern.ch</unsubscribe>
            <archive>https://groups.cern.ch/group/cristal-users/default.aspx</archive>
        </mailingList>
    </mailingLists>
    <properties>
        <jersey.version>2.16</jersey.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <additionalparam>-Xdoclint:none</additionalparam>
    </properties>

    <build>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
                <targetPath>META-INF/cristal</targetPath>
                <filtering>true</filtering>
                <includes>
                    <include>module.xml</include>
                </includes>
            </resource>
            <resource>
                <directory>src/main/resources</directory>
                <targetPath>org/cristalise/restapi/resources</targetPath>
                <excludes>
                    <exclude>module.xml</exclude>
                </excludes>
            </resource>
        </resources>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.5</version>
                <configuration>
                    <source>1.8</source>
                    <target>1.8</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>2.2.1</version>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <phase>verify</phase>
                        <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-release-plugin</artifactId>
                <version>2.4.1</version>
            </plugin>
            <plugin>
                <groupId>com.mycila</groupId>
                <artifactId>license-maven-plugin</artifactId>
                <version>2.11</version>
                <configuration>
                    <header>HEADER.txt</header>
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

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

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.glassfish.jersey</groupId>
                <artifactId>jersey-bom</artifactId>
                <version>${jersey.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <dependencies>
        <dependency>
            <groupId>org.glassfish.jersey.containers</groupId>
            <artifactId>jersey-container-grizzly2-http</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <artifactId>javax.ws.rs-api</artifactId>
            <groupId>javax.ws.rs</groupId>
            <version>2.0.1</version>
        </dependency>
        <dependency>
            <groupId>com.sun.jersey</groupId>
            <artifactId>jersey-json</artifactId>
            <version>1.8</version>
        </dependency>
        <dependency>
            <groupId>org.cristalise</groupId>
            <artifactId>cristalise-kernel</artifactId>
            <version>3.3.0</version>
        </dependency>
        <dependency>
            <groupId>org.json</groupId>
            <artifactId>json</artifactId>
            <version>20160810</version>
        </dependency>
    </dependencies>

    <profiles>
        <profile>
            <id>ossrh</id>
            <properties>
                <gpg.executable>gpg</gpg.executable>
                <gpg.keyname>${env.GPG_KEYNAME}</gpg.keyname>
                <gpg.passphrase>${env.GPG_PASSPHRASE}</gpg.passphrase>
                <gpg.defaultKeyring>false</gpg.defaultKeyring>
                <gpg.publicKeyring>${env.GPG_DIR}/pubring.gpg</gpg.publicKeyring>
                <gpg.secretKeyring>${env.GPG_DIR}/secring.gpg</gpg.secretKeyring>
            </properties>
            <activation>
                <property>
                    <name>performRelease</name>
                    <value>true</value>
                </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>
                    <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>
        </profile>
    </profiles>
</project>
