<?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">
    <modelVersion>4.0.0</modelVersion>

    <groupId>network.quant</groupId>
    <artifactId>overledger-sdk-java</artifactId>
    <version>1.0.0-alpha.2</version>

    <packaging>pom</packaging>

    <name>${project.groupId}:${project.artifactId}</name>
    <description>Quant Network Overledger SDK for Java, a Java based library for developing Overledger Mapp applications</description>
    <url>https://github.com/quantnetwork/overledger-sdk-java</url>

    <organization>
        <url>https://quant.network</url>
        <name>Quant Network</name>
    </organization>

    <inceptionYear>2018</inceptionYear>

    <developers>
        <developer>
            <name>Rui Wang</name>
            <email>rui.wang@quant.network</email>
            <organization>Quant Network</organization>
            <organizationUrl>https://quant.network</organizationUrl>
            <timezone>UTC+00:00</timezone>
        </developer>
    </developers>

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

    <scm>
        <connection>scm:git:git://github.com/quantnetwork/overledger-sdk-java.git</connection>
        <developerConnection>scm:git@github.com:quantnetwork/overledger-sdk-java.git</developerConnection>
        <url>https://github.com/quantnetwork/overledger-sdk-java</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>

    <issueManagement>
        <system>Github</system>
        <url>https://github.com/quantnetwork/overledger-sdk-java/issues</url>
    </issueManagement>

    <modules>
        <module>overledger-sdk-api</module>
        <module>overledger-sdk-essential</module>
        <module>overledger-sdk-bitcoin</module>
        <module>overledger-sdk-ethereum</module>
        <module>overledger-sdk-ripple</module>
        <module>overledger-sdk-bundle</module>
        <module>overledger-sdk-example</module>
    </modules>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <timestamp>${maven.build.timestamp}</timestamp>
        <java.version>11</java.version>
        <spring.boot.version>2.0.6.RELEASE</spring.boot.version>
        <jackson.version>2.9.8</jackson.version>
        <lombok.version>1.18.2</lombok.version>
        <bitcoinj.version>0.14.7</bitcoinj.version>
        <web3j.version>3.5.0</web3j.version>
        <json.version>20180813</json.version>
        <crypton.version>0.3.0</crypton.version>
        <jaxb.version>2.3.1</jaxb.version>
        <jaxb.core.version>2.3.0.1</jaxb.core.version>
        <jaxb.activation>1.1.1</jaxb.activation>
        <eddsa.version>0.3.0</eddsa.version>
        <json.version>20180813</json.version>
        <junit.jupiter.version>5.1.0</junit.jupiter.version>
        <junit.version>4.12</junit.version>
        <assertj.version>3.11.1</assertj.version>
        <mockito.version>2.23.0</mockito.version>
        <maven.compiler.version>3.8.0</maven.compiler.version>
        <maven.source.version>3.0.1</maven.source.version>
        <maven.javadoc.version>3.0.1</maven.javadoc.version>
        <maven.surefire.version>2.22.1</maven.surefire.version>
        <maven.jar.version>3.1.0</maven.jar.version>
        <maven.deploy.version>3.0.0-M1</maven.deploy.version>
        <maven.release.version>2.5.3</maven.release.version>
        <maven.scm.provider.gitexe>1.9.5</maven.scm.provider.gitexe>
        <nexus.staging.maven.plugin.version>1.6.7</nexus.staging.maven.plugin.version>
        <maven.gpg.plugin.version>1.6</maven.gpg.plugin.version>
    </properties>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-starter-web</artifactId>
                <version>${spring.boot.version}</version>
            </dependency>
            <dependency>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-starter-webflux</artifactId>
                <version>${spring.boot.version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-databind</artifactId>
                <version>${jackson.version}</version>
            </dependency>
            <dependency>
                <groupId>org.bitcoinj</groupId>
                <artifactId>bitcoinj-core</artifactId>
                <version>${bitcoinj.version}</version>
            </dependency>
            <dependency>
                <groupId>org.web3j</groupId>
                <artifactId>core</artifactId>
                <version>${web3j.version}</version>
            </dependency>
            <dependency>
                <groupId>org.projectlombok</groupId>
                <artifactId>lombok</artifactId>
                <version>${lombok.version}</version>
                <scope>provided</scope>
                <optional>true</optional>
            </dependency>
            <dependency>
                <groupId>org.json</groupId>
                <artifactId>json</artifactId>
                <version>${json.version}</version>
            </dependency>
            <dependency>
                <groupId>net.i2p.crypto</groupId>
                <artifactId>eddsa</artifactId>
                <version>${crypton.version}</version>
            </dependency>
            <dependency>
                <groupId>javax.xml.bind</groupId>
                <artifactId>jaxb-api</artifactId>
                <version>${jaxb.version}</version>
            </dependency>
            <dependency>
                <groupId>com.sun.xml.bind</groupId>
                <artifactId>jaxb-core</artifactId>
                <version>${jaxb.core.version}</version>
            </dependency>
            <dependency>
                <groupId>com.sun.xml.bind</groupId>
                <artifactId>jaxb-impl</artifactId>
                <version>${jaxb.version}</version>
            </dependency>
            <dependency>
                <groupId>javax.activation</groupId>
                <artifactId>activation</artifactId>
                <version>${jaxb.activation}</version>
            </dependency>
            <dependency>
                <groupId>net.i2p.crypto</groupId>
                <artifactId>eddsa</artifactId>
                <version>${eddsa.version}</version>
            </dependency>
            <dependency>
                <groupId>org.json</groupId>
                <artifactId>json</artifactId>
                <version>${json.version}</version>
            </dependency>
            <dependency>
                <groupId>org.junit.jupiter</groupId>
                <artifactId>junit-jupiter-api</artifactId>
                <version>${junit.jupiter.version}</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.junit.jupiter</groupId>
                <artifactId>junit-jupiter-engine</artifactId>
                <version>${junit.jupiter.version}</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.junit.platform</groupId>
                <artifactId>junit-platform-launcher</artifactId>
                <version>${junit.jupiter.version}</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.junit.platform</groupId>
                <artifactId>junit-platform-engine</artifactId>
                <version>${junit.jupiter.version}</version>
            </dependency>
            <dependency>
                <groupId>org.junit.platform</groupId>
                <artifactId>junit-platform-runner</artifactId>
                <version>${junit.jupiter.version}</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.mockito</groupId>
                <artifactId>mockito-core</artifactId>
                <version>${mockito.version}</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>junit</groupId>
                <artifactId>junit</artifactId>
                <version>${junit.version}</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>org.assertj</groupId>
                <artifactId>assertj-core</artifactId>
                <version>${assertj.version}</version>
                <scope>test</scope>
            </dependency>
            <dependency>
                <groupId>network.quant</groupId>
                <artifactId>overledger-sdk-api</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>network.quant</groupId>
                <artifactId>overledger-sdk-essential</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>network.quant</groupId>
                <artifactId>overledger-sdk-bitcoin</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>network.quant</groupId>
                <artifactId>overledger-sdk-ethereum</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>network.quant</groupId>
                <artifactId>overledger-sdk-ripple</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>network.quant</groupId>
                <artifactId>overledger-sdk-bundle</artifactId>
                <version>${project.version}</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <resources>
            <resource>
                <directory>${project.basedir}</directory>
                <includes>
                    <include>NOTICE*</include>
                    <include>LICENSE*</include>
                </includes>
            </resource>
        </resources>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>${maven.compiler.version}</version>
                    <configuration>
                        <encoding>UTF-8</encoding>
                        <source>${java.version}</source>
                        <target>${java.version}</target>
                        <showDeprecation>true</showDeprecation>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>${maven.source.version}</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>${maven.javadoc.version}</version>
                    <executions>
                        <execution>
                            <id>attach-javadocs</id>
                            <goals>
                                <goal>jar</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>${maven.surefire.version}</version>
                    <configuration>
                        <includes>
                            <include>**/*Test.java</include>
                        </includes>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>${maven.jar.version}</version>
                    <configuration>
                        <includes>
                            <include>**/*</include>
                        </includes>
                        <archive>
                            <index>true</index>
                            <manifestEntries>
                                <Built-At>${maven.build.timestamp}</Built-At>
                            </manifestEntries>
                        </archive>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>${maven.release.version}</version>
                    <configuration>
                        <localCheckout>true</localCheckout>
                        <pushChanges>false</pushChanges>
                        <mavenExecutorId>forked-path</mavenExecutorId>
                        <arguments>-Dgpg.passphrase=${gpg.passphrase}</arguments>
                    </configuration>
                    <dependencies>
                        <dependency>
                            <groupId>org.apache.maven.scm</groupId>
                            <artifactId>maven-scm-provider-gitexe</artifactId>
                            <version>${maven.scm.provider.gitexe}</version>
                        </dependency>
                    </dependencies>
                </plugin>
                <plugin>
                    <groupId>org.sonatype.plugins</groupId>
                    <artifactId>nexus-staging-maven-plugin</artifactId>
                    <version>${nexus.staging.maven.plugin.version}</version>
                    <extensions>true</extensions>
                    <configuration>
                        <serverId>ossrh</serverId>
                        <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                        <autoReleaseAfterClose>true</autoReleaseAfterClose>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <configuration>
                    <additionalOptions>-Xdoclint:none</additionalOptions>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>release</id>
            <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>${maven.gpg.plugin.version}</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
