<?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>io.github.check-leak</groupId>
   <artifactId>check-leak-parent</artifactId>
   <version>0.8</version>
   <packaging>pom</packaging>
   <inceptionYear>2023</inceptionYear>


   <name>CheckLeak</name>
   <description>Library to introspect the JVM to avoid and find memory leaks.</description>
   <url>https://github.com/check-leak/check-leak</url>

   <licenses>
      <license>
         <name>The Apache License, Version 2.0</name>
         <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      </license>
   </licenses>

   <scm>
      <connection>scm:git:https://github.com/check-leak/check-leak.git</connection>
      <developerConnection>scm:git:git@github.com:check-leak/check-leak.git</developerConnection>
      <url>https://github.com/check-leak/check-leak/</url>
      <tag>0.8</tag>
   </scm>

   <developers>
      <developer>
         <name>Clebert Suconic</name>
         <email>clebert.suconic@gmail.com</email>
      </developer>
      <developer>
         <name>George Gastaldi</name>
         <email>gegastaldi@gmail.com</email>
      </developer>
   </developers>

   <properties>
      <maven-gpg-plugin-version>1.6</maven-gpg-plugin-version>
      <maven.compiler.source>11</maven.compiler.source>
      <maven.compiler.target>11</maven.compiler.target>
      <version.junit>5.9.2</version.junit>
      <version.surefire>3.0.0-M6</version.surefire>
      <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
      <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
   </properties>

   <modules>
     <module>check-leak</module>
     <module>maven</module>
     <module>examples</module>
   </modules>

   <dependencyManagement>
      <dependencies>
         <dependency>
            <groupId>org.junit</groupId>
            <artifactId>junit-bom</artifactId>
            <version>${version.junit}</version>
            <type>pom</type>
            <scope>import</scope>
         </dependency>
      </dependencies>
   </dependencyManagement>

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


   <build>
      <pluginManagement>
         <plugins>
            <plugin>
               <groupId>org.apache.maven.plugins</groupId>
               <artifactId>maven-release-plugin</artifactId>
               <configuration>
                  <autoVersionSubmodules>true</autoVersionSubmodules>
                  <tagNameFormat>@{project.version}</tagNameFormat>
                  <pushChanges>false</pushChanges>
                  <arguments>-DskipTests</arguments>
               </configuration>
            </plugin>
         </plugins>
      </pluginManagement>
   </build>

   <profiles>
      <profile>
         <id>release</id>
         <activation>
            <property>
               <name>release</name>
               <value>true</value>
            </property>
         </activation>
         <build>
            <plugins>
               <plugin>
                  <groupId>org.apache.maven.plugins</groupId>
                  <artifactId>maven-gpg-plugin</artifactId>
                  <version>${maven-gpg-plugin-version}</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.7</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-source-plugin</artifactId>
                  <version>2.2.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>2.9.1</version>
                  <configuration>
                     <source>8</source>
                  </configuration>
                  <executions>
                     <execution>
                        <id>attach-javadocs</id>
                        <goals>
                           <goal>jar</goal>
                        </goals>
                     </execution>
                  </executions>
               </plugin>
            </plugins>
         </build>
      </profile>
   </profiles>

</project>
