<?xml version="1.0" encoding="UTF-8"?>
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xmlns="http://maven.apache.org/POM/4.0.0"
         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>org.passwordmaker</groupId>
    <artifactId>passwordmaker-je-lib</artifactId>
    <version>0.9.9</version>
    <packaging>jar</packaging>
    <name>PasswordMaker Library</name>
    <description>The library portion of the java edition of PasswordMaker.org passwordmaker.  Supports the Android passwordmaker project.</description>
    <url>http://www.passwordmaker.org</url>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>


    <licenses>
        <license>
            <name>GNU Lesser General Public License</name>
            <url>http://www.gnu.org/licenses/lgpl-3.0.html</url>
        </license>
    </licenses>

    <developers>
        <developer>
            <name>James Stapleton</name>
            <email>github@tasermonkeys.com</email>
            <organization>Passwordmaker.org</organization>
            <organizationUrl>http://www.passwordmaker.org</organizationUrl>
        </developer>
    </developers>

    <scm>
        <connection>scm:git:git@github.com:passwordmaker/java-passwordmaker-lib.git</connection>
        <developerConnection>scm:git:git@github.com:passwordmaker/java-passwordmaker-lib.git</developerConnection>
        <url>git@github.com:passwordmaker/java-passwordmaker-lib.git</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>

    <dependencies>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.8.1</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.bouncycastle</groupId>
            <artifactId>bcprov-jdk16</artifactId>
            <version>1.46</version>
            <!-- This must be TEST cause if its deployed with the jar
                 it may cause problems with other system's crypto libs
                 The application using this lib would have to include bouncycastle
                 if they need its crypto support.  This library doesn't use any
                 bouncy castle's api directly, just through the javax.crypto
                 api calls.
            -->
            <scope>test</scope>
        </dependency>
    </dependencies>
    <profiles>
        <profile>
            <!--
              This profile is intental so that developers don't have to have everything setup to
              build and develop.
            -->
            <id>build-for-central</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-javadoc-plugin</artifactId>
                        <version>2.9.1</version>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <!--
                      This requires gpg2 to be installed on your system.
                      Please see: http://central.sonatype.org/pages/working-with-pgp-signatures.html
                      -and- http://central.sonatype.org/pages/apache-maven.html#gpg-signed-components
                      If gpg2 is in your path, it seems to just works. And you don't need to add your
                      keyfile password to your settings.xml, if you have the gpg2 agent running.
                    -->
                    <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.2</version>
                      <extensions>true</extensions>
                      <configuration>
                        <serverId>ossrh</serverId>
                        <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                        <autoReleaseAfterClose>true</autoReleaseAfterClose>
                      </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
