<?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>com.composum.meta.ist</groupId>
    <artifactId>parent-root</artifactId>
    <version>1.5.2</version>
    <packaging>pom</packaging>

    <name>IST parent root</name>
    <description>Root for Parent-POM Projects of the IST Gmbh Dresden</description>
    <url>https://www.ist-software.com/</url>

    <licenses>
        <license>
            <name>MIT License</name>
            <url>http://www.opensource.org/licenses/mit-license.php</url>
        </license>
    </licenses>

    <developers>
        <developer>
            <name>Hans-Peter Störr</name>
            <email>hp.stoerr@ist-software.com</email>
            <organization>IST GmbH Dresden</organization>
            <organizationUrl>http://www.ist-software.com</organizationUrl>
        </developer>
        <developer>
            <name>Ralf Wunsch</name>
            <email>r.wunsch@ist-software.com</email>
            <organization>IST GmbH Dresden</organization>
            <organizationUrl>http://www.ist-software.com</organizationUrl>
        </developer>
        <developer>
            <name>Mirko Zeibig</name>
            <email>m.zeibig@ist-software.com</email>
            <organization>IST GmbH Dresden</organization>
            <organizationUrl>http://www.ist-software.com</organizationUrl>
        </developer>
    </developers>

    <properties>
        <release.repository.id>ossrh</release.repository.id>
        <release.repository.url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</release.repository.url>
        <release.autoReleaseAfterClose>false</release.autoReleaseAfterClose>
        <release.keyname>info@composum.com</release.keyname>

        <source.encoding>UTF-8</source.encoding>
        <project.build.sourceEncoding>${source.encoding}</project.build.sourceEncoding>
        <project.reporting.outputEncoding>${source.encoding}</project.reporting.outputEncoding>

        <java.source>1.8</java.source>
        <java.target>1.8</java.target>
        <maven.compiler.source>${java.source}</maven.compiler.source>
        <maven.compiler.target>${java.target}</maven.compiler.target>

        <package.company>IST GmbH Dresden</package.company>
        <package.install>/bin/cpm/package.service.html</package.install>

        <sling.starter.version>11</sling.starter.version>

        <!-- Some software versions -->
        <com.spotify.dockerfile.version>1.4.12</com.spotify.dockerfile.version>

        <!-- development properties placeholders -->
        <sling.scheme>http</sling.scheme>
        <sling.secure>false</sling.secure>
        <sling.host />
        <sling.port />
        <sling.context />
        <sling.user />
        <sling.password />
        <bundle.status.skip>true</bundle.status.skip>
    </properties>

    <distributionManagement>
        <repository>
            <id>${release.repository.id}</id>
            <url>${release.repository.url}</url>
        </repository>
        <snapshotRepository>
            <id>istrepo</id>
            <url>https://repo.ist-software.com/repository/maven-snapshots</url>
        </snapshotRepository>
        <site>
            <id>api.composum.com</id>
            <url>scp://api.composum.com/var/www/composum/api/public/</url>
        </site>
    </distributionManagement>

    <scm>
        <connection>scm:git:https://github.com/ist-dresden/composum-meta.git</connection>
        <developerConnection>scm:git:https://github.com/ist-dresden/composum-meta.git</developerConnection>
        <url>https://github.com/ist-dresden/composum-meta.git</url>
      <tag>parent-root-1.5.2</tag>
  </scm>

    <modules>
        <module>2</module>
        <module>2/public</module>
    </modules>

    <profiles>
        <profile>
            <!-- profile to release the artifacts for the public repository -->
            <id>nexus-staging</id>
            <build>
                <plugins>
                    <!-- https://mvnrepository.com/artifact/org.sonatype.plugins/nexus-staging-maven-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://oss.sonatype.org/</nexusUrl>
                            <!--
                                As we switch to releasing via Github, we do not want the stuff to be immediately released, since
                                we want things to be as resilient as possible: the git push of the release commits
                                happens only after things are successfully uploaded to sonatype and the release happens only after the git push.
                                A release can then be triggered by mvn nexus-staging:release in target/checkout , or in the Nexus UI.
                            -->
                            <autoReleaseAfterClose>${release.autoReleaseAfterClose}</autoReleaseAfterClose>
                        </configuration>
                    </plugin>

                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>3.5.0</version>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                        <configuration>
                            <failOnError>false</failOnError>
                        </configuration>
                    </plugin>

                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>

                    <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-gpg-plugin -->
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>3.0.1</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <keyname>${release.keyname}</keyname>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
