<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <modelVersion>4.0.0</modelVersion>
  <groupId>net.codesup.util</groupId>
  <artifactId>jaxb-plugin-parent</artifactId>
  <version>2.1.1.1</version>
  <packaging>pom</packaging>
  <name>Parent POM for CodeSup JAXB XJC plugin projects</name>
  <description>Provides base settings and dependencies for other jaxb-plugin projects.</description>
  <url>https://mklemm.github.io/jaxb-plugin-parent</url>
  <licenses>
    <license>
      <name>MIT License</name>
      <url>http://opensource.org/licenses/MIT</url>
    </license>
  </licenses>
  <developers>
    <developer>
      <name>Mirko Klemm</name>
      <email>mk@klemm-scs.com</email>
    </developer>
  </developers>
  <scm>
    <connection>scm:git:https://github.com/mklemm/jaxb-plugin-parent.git</connection>
    <developerConnection>scm:git:https://github.com/mklemm/jaxb-plugin-parent.git</developerConnection>
    <url>https://github.com/mklemm/jaxb-plugin-parent</url>
  </scm>
  <distributionManagement>
    <site>
      <id>github</id>
      <url>scm:git:https://github.com/mklemm/jaxb-plugin-parent.git</url>
    </site>
  </distributionManagement>
  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <jaxb.impl.version>4.0.5</jaxb.impl.version>
    <jaxb.version>4.0.2</jaxb.version>
    <github.global.server>github</github.global.server>
  </properties>
  <dependencies>
    <dependency>
      <groupId>jakarta.xml.bind</groupId>
      <artifactId>jakarta.xml.bind-api</artifactId>
      <version>${jaxb.version}</version>
    </dependency>
    <dependency>
      <groupId>com.sun.xml.bind</groupId>
      <artifactId>jaxb-impl</artifactId>
      <version>${jaxb.impl.version}</version>
    </dependency>
    <dependency>
      <groupId>org.glassfish.jaxb</groupId>
      <artifactId>jaxb-xjc</artifactId>
      <version>${jaxb.impl.version}</version>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.13.2</version>
      <scope>test</scope>
    </dependency>
  </dependencies>
  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <artifactId>maven-scm-publish-plugin</artifactId>
          <version>3.0.0</version>
          <configuration>
            <scmBranch>gh-pages</scmBranch>
            <content>target/${project.artifactId}</content>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-source-plugin</artifactId>
          <version>3.2.1</version>
          <executions>
            <execution>
              <id>attach-sources</id>
              <phase>package</phase>
              <goals>
                <goal>jar-no-fork</goal>
                <goal>test-jar-no-fork</goal>
              </goals>
              <configuration>
                <includePom>true</includePom>
              </configuration>
            </execution>
          </executions>
        </plugin>
        <plugin>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>3.6.3</version>
          <configuration>
            <source>13</source>
            <maxmemory>512m</maxmemory>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>
    <plugins>
      <plugin>
        <groupId>org.jvnet.jaxb</groupId>
        <artifactId>jaxb-maven-plugin</artifactId>
        <version>4.0.0</version>
        <executions>
          <execution>
            <id>xsd-generate-2.2</id>
            <phase>generate-sources</phase>
            <goals>
              <goal>generate</goal>
            </goals>
          </execution>
        </executions>
        <dependencies>
          <dependency>
            <groupId>jakarta.xml.bind</groupId>
            <artifactId>jakarta.xml.bind-api</artifactId>
            <version>${jaxb.version}</version>
          </dependency>
          <dependency>
            <groupId>com.sun.xml.bind</groupId>
            <artifactId>jaxb-impl</artifactId>
            <version>${jaxb.impl.version}</version>
          </dependency>
        </dependencies>
        <configuration>
          <schemaIncludes>
            <schemaInclude>**/*.xsd</schemaInclude>
          </schemaIncludes>
          <strict>true</strict>
          <verbose>true</verbose>
          <extension>true</extension>
          <removeOldOutput>true</removeOldOutput>
          <specVersion>2.3</specVersion>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>3.8.0</version>
        <inherited>true</inherited>
        <configuration>
          <source>13</source>
          <target>13</target>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-javadoc-plugin</artifactId>
      </plugin>
      <plugin>
        <artifactId>maven-site-plugin</artifactId>
        <version>4.0.0-M13</version>
        <dependencies>
          <dependency>
            <groupId>org.apache.maven.doxia</groupId>
            <artifactId>doxia-decoration-model</artifactId>
            <version>1.11.1</version>
          </dependency>
        </dependencies>
      </plugin>
      <plugin>
        <artifactId>maven-resources-plugin</artifactId>
        <version>2.6</version>
        <executions>
          <execution>
            <id>copy-resources</id>
            <phase>generate-resources</phase>
            <goals>
              <goal>copy-resources</goal>
            </goals>
            <configuration>
              <outputDirectory>${project.build.outputDirectory}</outputDirectory>
              <resources>
                <resource>
                  <directory>src/main/java</directory>
                  <includes>
                    <include>com/kscs/util/jaxb/*</include>
                  </includes>
                  <filtering>true</filtering>
                </resource>
              </resources>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>com.github.danielflower.mavenplugins</groupId>
        <artifactId>multi-module-maven-release-plugin</artifactId>
        <version>3.6.4</version>
        <configuration>
          <releaseGoals>
            <releaseGoal>deploy</releaseGoal>
          </releaseGoals>
          <releaseProfiles>
            <releaseProfile>release</releaseProfile>
          </releaseProfiles>
          <serverId>github</serverId>
        </configuration>
      </plugin>
    </plugins>
  </build>
  <profiles>
    <profile>
      <id>release</id>
      <build>
        <plugins>
          <plugin>
            <artifactId>maven-javadoc-plugin</artifactId>
            <executions>
              <execution>
                <id>javadoc</id>
                <phase>package</phase>
                <goals>
                  <goal>jar</goal>
                </goals>
              </execution>
            </executions>
          </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>
              <autoReleaseAfterClose>true</autoReleaseAfterClose>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-source-plugin</artifactId>
            <version>3.2.1</version>
            <executions>
              <execution>
                <id>attach-sources</id>
                <phase>package</phase>
                <goals>
                  <goal>jar-no-fork</goal>
                  <goal>test-jar-no-fork</goal>
                </goals>
                <configuration>
                  <includePom>true</includePom>
                </configuration>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>1.5</version>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
                <configuration>
                  <executable>/opt/homebrew/bin/gpg</executable>
                  <gpgArguments>
                    <arg>--pinentry-mode</arg>
                    <arg>loopback</arg>
                  </gpgArguments>
                </configuration>
              </execution>
            </executions>
            <configuration>
              <keyname>mirko@cm-klemm.de</keyname>
            </configuration>
          </plugin>
        </plugins>
      </build>
      <distributionManagement>
        <repository>
          <id>ossrh</id>
          <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
        <snapshotRepository>
          <id>ossrh</id>
          <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
      </distributionManagement>
    </profile>
  </profiles>
</project>
