<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>com.forio.epicenter</groupId>
  <artifactId>epicenter-model</artifactId>
  <version>2.3.0</version>
  <packaging>pom</packaging>
  <name>Model</name>
  <description>Root POM</description>
  <url>https://github.com/forio/epicenter-model</url>
  <licenses>
    <license>
      <name>Apache License, Version 2.0</name>
      <url>https://www.apache.org/licenses/LICENSE-2.0</url>
      <distribution>repo</distribution>
    </license>
  </licenses>
  <scm>
    <connection>scm:git@github.com:forio/epicenter-model.git</connection>
    <developerConnection>scm:git@github.com:forio/epicenter-model.git</developerConnection>
    <url>https://github.com/forio/epicenter-model</url>
  </scm>
  <developers>
    <developer>
      <id>david.berkman</id>
      <name>David Berkman</name>
      <email>dberkman@forio.com</email>
    </developer>
    <developer>
      <id>will.glass-husain</id>
      <name>Will Glass-Husain</name>
      <email>wglass@forio.com</email>
    </developer>
  </developers>

  <profiles>
    <profile>
      <id>oss</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
          </plugin>
          <plugin>
            <groupId>org.sonatype.plugins</groupId>
            <artifactId>nexus-staging-maven-plugin</artifactId>
            <extensions>true</extensions>
            <configuration>
              <serverId>oss</serverId>
              <nexusUrl>https://oss.sonatype.org/</nexusUrl>
              <autoReleaseAfterClose>true</autoReleaseAfterClose>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

  <distributionManagement>
    <repository>
      <id>${nexus.releases.id}</id>
      <name>Nexus Release Repository</name>
      <url>${nexus.releases.url}</url>
    </repository>
    <snapshotRepository>
      <id>${nexus.snapshots.id}</id>
      <name>Nexus Snapshot Repository</name>
      <url>${nexus.snapshots.url}</url>
    </snapshotRepository>
  </distributionManagement>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <graal.version>21.3.0</graal.version>
    <jaxb.version>2.3.1</jaxb.version>
  </properties>

  <modules>
    <module>api</module>
  </modules>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>javax.xml.bind</groupId>
        <artifactId>jaxb-api</artifactId>
        <version>${jaxb.version}</version>
      </dependency>
      <dependency>
        <groupId>com.sun.xml.bind</groupId>
        <artifactId>jaxb-impl</artifactId>
        <version>${jaxb.version}</version>
      </dependency>
      <dependency>
        <groupId>org.graalvm.sdk</groupId>
        <artifactId>graal-sdk</artifactId>
        <version>${graal.version}</version>
      </dependency>
    </dependencies>
  </dependencyManagement>
  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>2.22.2</version>
          <configuration>
            <useSystemClassLoader>false</useSystemClassLoader>
            <groups>unit</groups>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-source-plugin</artifactId>
          <version>3.1.0</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-compiler-plugin</artifactId>
          <version>3.8.1</version>
          <configuration>
            <source>11</source>
            <target>11</target>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>3.1.1</version>
          <executions>
            <execution>
              <id>attach-javadocs</id>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
        <plugin>
          <groupId>org.sonatype.plugins</groupId>
          <artifactId>nexus-staging-maven-plugin</artifactId>
          <version>1.6.8</version>
        </plugin>
        <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.smallmind</groupId>
          <artifactId>smallmind-license-plugin</artifactId>
          <version>4.7.1</version>
          <executions>
            <execution>
              <id>generate</id>
              <goals>
                <goal>generate-notice-headers</goal>
              </goals>
            </execution>
            <execution>
              <id>install</id>
              <goals>
                <goal>install-license-files</goal>
              </goals>
            </execution>
          </executions>
          <configuration>
            <root>
              <groupId>com.forio.epicenter</groupId>
              <artifactId>epicenter-model</artifactId>
            </root>
            <licenses>
              <license>APACHE</license>
            </licenses>
            <includeTests>true</includeTests>
            <rules>
              <rule>
                <notice>COPYRIGHT</notice>
                <fileTypes>
                  <fileType>*.java</fileType>
                </fileTypes>
                <stencilId>org.smallmind.license.stencil.JavaDocStencil</stencilId>
              </rule>
            </rules>
          </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>
    </plugins>
  </build>
</project>
