<?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>org.mustangproject</groupId>
    <artifactId>core</artifactId>
    <version>2.15.2-SNAPSHOT</version>
    <packaging>pom</packaging>
    <name>Mustang</name>

    <modules>
        <module>library</module>
        <module>validator</module>
        <module>Mustang-CLI</module>
    </modules>

    <description>Mustangproject is a java library and commandline tool to read, validate, write and convert EN16931 e-invoices, e.g. Factur-X and XRechnung (read and writing CII and reading also UBL).
    </description>
    <url>http://www.mustangproject.org/</url>
    <scm>
        <connection>scm:git:git://github.com/dexecutor/dependent-tasks-executor.git</connection>
        <developerConnection>scm:git:git@github.com:dexecutor/dexecutor.git</developerConnection>
        <url>https://github.com/dexecutor/dependent-tasks-executor</url>
      <tag>core-2.3.2</tag>
  </scm>
    <build>
        <pluginManagement>
            <plugins>
                <plugin><!-- mvn help:effective-pom will otherwise tell it just defaults
						to 2.3.2 - which does not release in the maven repo, and neither shows any
						error message :-( -->
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>2.5.3</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>1.9.5</version>
                        </dependency>
                    </dependencies>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.0.1</version>
                <configuration>

                    <excludePackageNames>org.mustangproject.ZUGFeRD.model.*</excludePackageNames>

                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-deploy-plugin</artifactId>
                <version>3.0.0-M1</version>
                <configuration>
                    <altDeploymentRepository>internal.repo::default::file://${project.build.directory}/mvn-repo
                    </altDeploymentRepository>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
                <version>1.6.13</version>
                <extensions>true</extensions>
                <configuration>
                    <serverId>ossrh</serverId>
                    <nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
                    <autoReleaseAfterClose>true</autoReleaseAfterClose>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <configuration>
                    <runOrder>alphabetical</runOrder>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.2.1</version>
                <configuration>
                    <encoding>UTF-8</encoding>
                </configuration>
                <executions>
                    <execution>
                        <id>attach-javadoc</id>
                    </execution>
                </executions>
            </plugin>

        </plugins>
    </build>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
    </distributionManagement>
    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <github.global.server>github</github.global.server>
        <additionalparam>-Xdoclint:none</additionalparam>
        <!-- Skip error check for javadoc -->
        <maven.compiler.compilerVersion>11</maven.compiler.compilerVersion>
        <maven.compiler.source>11</maven.compiler.source>
        <maven.compiler.target>11</maven.compiler.target>
        <maven.deploy.skip>true</maven.deploy.skip><!-- prevent this to be deployed to maven central as "core",
        we only want submodules, see also https://stackoverflow.com/questions/7446599/how-to-deploy-only-the-sub-modules-using-maven-deploy-->
    </properties>

    <mailingLists>
        <mailingList>
            <name>User List</name>
            <archive>https://groups.google.com/forum/?hl=de#!forum/mustangproject</archive>
        </mailingList>
    </mailingLists>
    <licenses>
        <license>
            <name>Apache-2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
            <comments>A business-friendly OSS license</comments>
        </license>
    </licenses>
    <developers>
        <developer>
            <name>Jochen Stärk</name>
            <email>jstaerk@usegroup.de</email>
            <roles>
                <role>architect</role>
                <role>developer</role>
            </roles>
        </developer>
        <developer>
            <name>Alexander Schmidt</name>
            <email>schmidt.alexander@mail.de</email>
            <roles>
                <role>developer</role>
            </roles>
        </developer>
    </developers>
    <profiles>


        <!-- GPG Signature on release -->

        <profile>
            <id>release-sign-artifacts</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>1.6</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-toolchains-plugin</artifactId>
                        <version>3.1.0</version>
                        <executions>
                            <execution>
                                <goals>
                                    <goal>toolchain</goal>
                                </goals>
                            </execution>
                        </executions>
                        <configuration>
                            <toolchains>
                                <jdk>
                                    <version>11</version>
                                    <vendor>adopt</vendor>
                                </jdk>
                            </toolchains>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
