<?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>

  <name>Spring Data JPA EntityGraph Parent</name>
  <description>A Spring Data JPA extension allowing full usage of JPA EntityGraph on repositories</description>
  <url>https://github.com/Cosium/spring-data-jpa-entity-graph</url>

  <groupId>com.cosium.spring.data</groupId>
  <artifactId>spring-data-jpa-entity-graph-parent</artifactId>
  <version>2.4.2</version>
  <packaging>pom</packaging>

  <modules>
    <module>core</module>
    <module>generator</module>
  </modules>

  <properties>
    <source.level>1.8</source.level>
    <maven-git-code-format.version>1.6</maven-git-code-format.version>
  </properties>

  <build>
    <plugins>
      <plugin>
        <groupId>com.cosium.code</groupId>
        <artifactId>maven-git-code-format</artifactId>
        <version>1.13</version>
        <configuration>
          <truncateHooksBaseScripts>true</truncateHooksBaseScripts>
        </configuration>
        <executions>
          <execution>
            <goals>
              <goal>install-hooks</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>3.8.0</version>
        <configuration>
          <source>${source.level}</source>
          <target>${source.level}</target>
          <parameters>true</parameters>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <version>3.0.1</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>3.2.0</version>
        <executions>
          <execution>
            <id>attach-javadocs</id>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <failOnError>false</failOnError>
          <additionalOptions>-Xdoclint:none</additionalOptions>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-deploy-plugin</artifactId>
        <version>2.8.2</version>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <version>2.22.2</version>
        <configuration>
          <trimStackTrace>false</trimStackTrace>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-release-plugin</artifactId>
        <version>2.5.3</version>
        <configuration>
          <pushChanges>false</pushChanges>
          <localCheckout>true</localCheckout>
          <autoVersionSubmodules>true</autoVersionSubmodules>
          <useReleaseProfile>true</useReleaseProfile>
          <releaseProfiles>release</releaseProfiles>
          <goals>deploy</goals>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <version>0.8.6</version>
        <executions>
          <execution>
            <goals>
              <goal>prepare-agent</goal>
            </goals>
          </execution>
          <execution>
            <id>report</id>
            <phase>test</phase>
            <goals>
              <goal>report</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>

  <profiles>
    <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.sonatype.plugins</groupId>
            <artifactId>nexus-staging-maven-plugin</artifactId>
            <version>1.6.8</version>
            <extensions>true</extensions>
            <configuration>
              <serverId>ossrh</serverId>
              <nexusUrl>https://oss.sonatype.org/</nexusUrl>
              <autoReleaseAfterClose>true</autoReleaseAfterClose>
              <autoDropAfterRelease>true</autoDropAfterRelease>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

  <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>

  <scm>
    <connection>scm:git:https://github.com/Cosium/spring-data-jpa-entity-graph</connection>
    <developerConnection>scm:git:https://github.com/Cosium/spring-data-jpa-entity-graph</developerConnection>
    <url>https://github.com/Cosium/spring-data-jpa-entity-graph</url>
    <tag>spring-data-jpa-entity-graph-parent-2.4.2</tag>
  </scm>

  <organization>
    <name>Cosium</name>
    <url>http://www.cosium.com</url>
  </organization>

  <developers>
    <developer>
      <id>reda-alaoui</id>
      <name>Réda Housni Alaoui</name>
      <email>reda.housnialaoui@cosium.com</email>
      <url>https://github.com/reda-alaoui</url>
    </developer>
  </developers>

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

</project>
