codeowners-parent
Used in:
components
- OverviewOverview
- VersionsVersions
- DependentsDependents
- DependenciesDependencies
<dependency>
<groupId>nl.basjes.codeowners</groupId>
<artifactId>codeowners-parent</artifactId>
<version>2.0.0</version>
</dependency><!--
~ CodeOwners Tools
~ Copyright (C) 2023-2026 Niels Basjes
~
~ Licensed under the Apache License, Version 2.0 (the "License");
~ you may not use this file except in compliance with the License.
~ You may obtain a copy of the License at
~
~ https://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing, software
~ distributed under the License is distributed on an AS IS BASIS,
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~ See the License for the specific language governing permissions and
~ limitations under the License.
-->
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>nl.basjes.codeowners</groupId>
<artifactId>codeowners-parent</artifactId>
<version>2.0.0</version>
<packaging>pom</packaging>
<name>CODEOWNERS Tools:</name>
<description>A library to use and verify the CODEOWNERS and .gitignore files.</description>
<url>https://github.com/nielsbasjes/codeowners</url>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.build.outputEncoding>UTF-8</project.build.outputEncoding>
<kotlin.code.style>official</kotlin.code.style>
<jvm.version>11</jvm.version>
<kotlin.compiler.jvmTarget>${jvm.version}</kotlin.compiler.jvmTarget>
<kotlin.version>2.3.21</kotlin.version>
<dokka-maven-plugin.version>2.1.0</dokka-maven-plugin.version>
<!-- Needed to make the build reproducible https://reproducible-builds.org/ -->
<project.build.outputTimestamp>2026-05-26T16:50:47Z</project.build.outputTimestamp>
<maven.version>3.9.16</maven.version>
<maven.minimal.version>3.9.2</maven.minimal.version>
<enforcer-api.version>3.6.3</enforcer-api.version>
<maven.compiler.source>${jvm.version}</maven.compiler.source>
<maven.compiler.target>${jvm.version}</maven.compiler.target>
<maven.compiler.release>${jvm.version}</maven.compiler.release>
<maven-artifact-plugin.version>3.6.1</maven-artifact-plugin.version>
<maven-clean-plugin.version>3.5.0</maven-clean-plugin.version>
<maven-compiler-plugin.version>3.15.0</maven-compiler-plugin.version>
<maven-enforcer-plugin.version>3.6.3</maven-enforcer-plugin.version>
<maven-failsafe-plugin.version>3.1.0</maven-failsafe-plugin.version>
<maven-gpg-plugin.version>3.2.8</maven-gpg-plugin.version>
<maven-install-plugin.version>3.1.1</maven-install-plugin.version>
<maven-invoker-plugin.version>3.10.1</maven-invoker-plugin.version>
<maven-jar-plugin.version>3.5.0</maven-jar-plugin.version>
<maven-javadoc-plugin.version>3.12.0</maven-javadoc-plugin.version>
<maven-release-plugin.version>3.0.0</maven-release-plugin.version>
<maven-resources-plugin.version>3.5.0</maven-resources-plugin.version>
<maven-source-plugin.version>3.4.0</maven-source-plugin.version>
<maven-surefire-plugin.version>3.5.5</maven-surefire-plugin.version>
<maven-toolchains-plugin.version>3.2.0</maven-toolchains-plugin.version>
<apache-rat-plugin.version>0.18</apache-rat-plugin.version>
<git-commit-id-maven-plugin.version>10.0.0</git-commit-id-maven-plugin.version>
<cyclonedx-maven-plugin.version>2.9.1</cyclonedx-maven-plugin.version>
<antlr.version>4.13.2</antlr.version>
<junit.version>6.1.0</junit.version>
<slf4j.version>2.0.18</slf4j.version>
<logback.version>1.5.32</logback.version>
<jackson.version>2.21.3</jackson.version>
<jacoco-maven-plugin.version>0.8.14</jacoco-maven-plugin.version>
<!-- See http://www.eclemma.org/jacoco/trunk/doc/prepare-agent-mojo.html-->
<jacoco.surefireArgLine />
<argLine>@{jacoco.surefireArgLine} -Xmx2048m</argLine>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-test-junit5</artifactId>
<version>${kotlin.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit</groupId>
<artifactId>junit-bom</artifactId>
<version>${junit.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>org.antlr</groupId>
<artifactId>antlr4-runtime</artifactId>
<version>[${antlr.version}]</version> <!-- Pin is HARD to this specific version -->
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${slf4j.version}</version>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>${logback.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit-pioneer</groupId>
<artifactId>junit-pioneer</artifactId>
<version>2.3.0</version>
<scope>test</scope>
</dependency>
</dependencies>
</dependencyManagement>
<modules>
<module>codeowners-reader</module>
<module>gitignore-reader</module>
<module>codeowners-validator</module>
<module>enforcer</module>
</modules>
<profiles>
<profile>
<id>skipQuality</id>
<properties>
<skipTests>true</skipTests>
<sonar.skip>true</sonar.skip>
<rat.skip>true</rat.skip>
<checkstyle.skip>true</checkstyle.skip>
<jacoco.skip>true</jacoco.skip>
<spotbugs.skip>true</spotbugs.skip>
<dependency-convergence.phase>none</dependency-convergence.phase>
<docker-based-tests.skip>true</docker-based-tests.skip>
<invoker.skip>true</invoker.skip>
<cyclonedx.skip>true</cyclonedx.skip>
<gpg.skip>true</gpg.skip>
</properties>
</profile>
<profile>
<id>artifactCompare</id>
<build>
<defaultGoal>clean verify</defaultGoal>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-artifact-plugin</artifactId>
<version>${maven-artifact-plugin.version}</version>
<executions>
<execution>
<id>compare</id>
<goals>
<goal>compare</goal>
</goals>
<phase>verify</phase>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>packageForRelease</id>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-artifact-plugin</artifactId>
<version>${maven-artifact-plugin.version}</version>
<executions>
<execution>
<id>Ensure plugins are reproducible</id>
<phase>validate</phase>
<goals>
<goal>check-buildplan</goal>
</goals>
</execution>
<execution>
<id>Generate buildinfo</id>
<goals>
<goal>buildinfo</goal>
</goals>
<configuration>
<attach>true</attach>
</configuration>
</execution>
</executions>
</plugin>
<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>
<configuration>
<gpgArguments>
<arg>--pinentry-mode</arg>
<arg>loopback</arg>
</gpgArguments>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>${maven-javadoc-plugin.version}</version>
<executions>
<execution>
<id>attach-javadocs</id>
<configuration>
<!-- The creation of the javadoc jar is done for pure Kotlin projects by the dokka plugin. -->
<skip>true</skip>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.jetbrains.dokka</groupId>
<artifactId>dokka-maven-plugin</artifactId>
<version>${dokka-maven-plugin.version}</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>javadocJar</goal>
</goals>
</execution>
</executions>
</plugin>
<!-- https://central.sonatype.org/publish/publish-portal-maven/ -->
<plugin>
<groupId>org.sonatype.central</groupId>
<artifactId>central-publishing-maven-plugin</artifactId>
<version>0.10.0</version>
<extensions>true</extensions>
<configuration>
<publishingServerId>central</publishingServerId>
<deploymentName>Codeowners ${project.version}</deploymentName>
<!-- <autoPublish>true</autoPublish>-->
<!-- <waitUntil>published</waitUntil>-->
<waitUntil>validated</waitUntil>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-maven-plugin</artifactId>
<version>${kotlin.version}</version>
<extensions>true</extensions>
<executions>
<execution>
<id>compile</id>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
<execution>
<id>test-compile</id>
<phase>test-compile</phase>
<goals>
<goal>test-compile</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>${maven-resources-plugin.version}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>${maven-jar-plugin.version}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${maven-surefire-plugin.version}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-toolchains-plugin</artifactId>
<version>${maven-toolchains-plugin.version}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-artifact-plugin</artifactId>
<version>${maven-artifact-plugin.version}</version>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>3.6.3</version>
<executions>
<execution>
<id>Setup git commit hooks</id>
<phase>validate</phase>
<goals>
<goal>exec</goal>
</goals>
<configuration>
<executable>git</executable>
<arguments>
<argument>config</argument>
<argument>core.hooksPath</argument>
<argument>.git-hooks/</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-toolchains-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>select-jdk-toolchain</goal>
</goals>
<configuration>
<version>[21,22)</version>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>${maven-source-plugin.version}</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-clean-plugin</artifactId>
<version>${maven-clean-plugin.version}</version>
<configuration>
<filesets>
<fileset>
<directory>${project.basedir}</directory>
<includes>
<!-- Cleaning the intermediate files from maven-shade-plugin. -->
<include>dependency-reduced-pom.xml</include>
</includes>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>${maven-enforcer-plugin.version}</version>
<executions>
<execution>
<id>Check build environment requirements</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<fail>true</fail>
<rules>
<requireMavenVersion>
<version>[${maven.minimal.version},)</version>
<message>You must use Maven version ${maven.minimal.version} or newer to build this project.</message>
<!-- Reasons for this need: -->
<!-- https://issues.apache.org/jira/browse/MDEPLOY-221 -->
<!-- https://issues.apache.org/jira/browse/MNG-6581 -->
</requireMavenVersion>
<requireJavaVersion>
<version>[25,26)</version>
<message>To ensure the build being reproducible the code MUST be built with Java JDK 25 (detected: JDK ${java.version}).</message>
</requireJavaVersion>
<banDuplicateClasses>
<scopes>
<scope>compile</scope>
<scope>runtime</scope>
<!-- <scope>provided</scope>-->
</scopes>
<findAllDuplicates>true</findAllDuplicates>
<ignoreWhenIdentical>true</ignoreWhenIdentical>
</banDuplicateClasses>
<enforceBytecodeVersion>
<maxJdkVersion>11</maxJdkVersion>
<ignoredScopes>
<ignoredScope>test</ignoredScope>
</ignoredScopes>
</enforceBytecodeVersion>
<dependencyConvergence />
</rules>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.codehaus.mojo</groupId>
<artifactId>extra-enforcer-rules</artifactId>
<version>1.12.0</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>${maven-compiler-plugin.version}</version>
<configuration>
<compilerArgs>
<!-- Enable almost all warnings. -->
<!-- Ignore 'classfile' to allow leaving Kryo out. -->
<!-- Ignore 'processing' to avoid "No processor claimed any of these annotations" in several places. -->
<!-- Ignore 'serial' warnings about not having a serialVersionUID -->
<!-- Ignore 'path' warnings (some dependencies have a bad classpath in their MANIFEST.MF) -->
<!-- [WARNING] [path] bad path element -->
<!-- "/home/nbasjes/.m2/repository/org/scala-lang/scala-compiler/2.12.7/scala-reflect.jar": -->
<!-- no such file or directory -->
<!-- https://stackoverflow.com/questions/41944939/maven-build-failure-involving-manifest-mf-classpath-in-dependency-jars -->
<!-- https://stackoverflow.com/questions/1344202/bad-path-warning-where-is-it-coming-from -->
<!-- Ignore 'options' warnings about java 8 being obsolete -->
<arg>-Xlint:all,-classfile,-processing,-serial,-path,-options</arg>
<arg>-Werror</arg>
<arg>-implicit:class</arg>
</compilerArgs>
<showWarnings>true</showWarnings>
<showDeprecation>true</showDeprecation>
</configuration>
</plugin>
<plugin>
<!-- Description: https://github.com/git-commit-id/git-commit-id-maven-plugin -->
<groupId>io.github.git-commit-id</groupId>
<artifactId>git-commit-id-maven-plugin</artifactId>
<version>${git-commit-id-maven-plugin.version}</version>
<executions>
<execution>
<id>get-the-git-infos</id>
<phase>validate</phase>
<goals>
<goal>revision</goal>
</goals>
</execution>
</executions>
<configuration>
<dateFormat>yyyy-MM-dd '@' HH:mm:ss z</dateFormat>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.rat</groupId>
<artifactId>apache-rat-plugin</artifactId>
<version>${apache-rat-plugin.version}</version>
<inherited>false</inherited>
<executions>
<execution>
<phase>validate</phase>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
<configuration>
<consoleOutput>true</consoleOutput>
<excludeSubProjects>false</excludeSubProjects>
<inputExcludes>
<!-- Build config files -->
<inputExlude>.mvn/jvm.config</inputExlude>
<!-- Version control files -->
<inputExlude>**/.git/**</inputExlude>
<inputExlude>**/.gitignore</inputExlude>
<inputExlude>**/.gitmodules</inputExlude>
<!-- IDE settings and files -->
<inputExlude>**/.classpath</inputExlude>
<inputExlude>**/.project</inputExlude>
<inputExlude>**/.settings/**</inputExlude>
<inputExlude>**/.idea/**</inputExlude>
<inputExlude>**/*.iml</inputExlude>
<inputExlude>**/.run/**</inputExlude>
<inputExlude>**/*.patch</inputExlude>
<inputExlude>**/*.diff</inputExlude>
<!-- Test files that should not be 'polluted' -->
<inputExlude>gitignore-reader/src/test/resources/testtree/</inputExlude>
<inputExlude>enforcer/src/it/testtree/</inputExlude>
<inputExlude>codeowners-validator/src/test/resources/testdirectories/</inputExlude>
<!-- Files that cannot be 'polluted' -->
<inputExlude>.github/**</inputExlude>
<inputExlude>**/*.json</inputExlude>
<inputExlude>**/*.ndjson</inputExlude>
<!-- Files generated during build and/or development -->
<inputExlude>**/target/**</inputExlude>
<inputExlude>**/gen/**</inputExlude>
<inputExlude>**/dependency-reduced-pom.xml</inputExlude>
<!-- Test scripts -->
<inputExlude>*.sh</inputExlude>
<inputExlude>**/_*/**</inputExlude>
<inputExlude>**/*_/**</inputExlude>
<inputExlude>**/gitignore-reader/src/test/resources/**</inputExlude>
</inputExcludes>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>${maven-surefire-plugin.version}</version>
<configuration>
<environmentVariables>
<XDG_CONFIG_HOME>src/test/resources/xdg_config_home</XDG_CONFIG_HOME>
</environmentVariables>
</configuration>
</plugin>
<!-- Coverage analysis for tests -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco-maven-plugin.version}</version>
<executions>
<!--
Prepares the property pointing to the JaCoCo runtime agent which
is passed as VM argument when Maven the Surefire plugin is executed.
-->
<execution>
<id>pre-unit-test</id>
<goals>
<goal>prepare-agent</goal>
</goals>
<configuration>
<!--
Sets the name of the property containing the settings
for JaCoCo runtime agent.
-->
<propertyName>jacoco.surefireArgLine</propertyName>
</configuration>
</execution>
<!--
Ensures that the code coverage report for unit tests is created after
unit tests have been run.
-->
<execution>
<id>post-unit-test</id>
<phase>test</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>3.3.1</version>
<dependencies>
<dependency>
<groupId>nl.basjes.maven.release</groupId>
<artifactId>conventional-commits-version-policy</artifactId>
<version>1.0.9</version>
</dependency>
</dependencies>
<configuration>
<autoVersionSubmodules>true</autoVersionSubmodules>
<scmCommentPrefix>Release:</scmCommentPrefix>
<scmReleaseCommitComment>Release: Version @{releaseLabel}</scmReleaseCommitComment>
<scmDevelopmentCommitComment>Release: Start development of next version</scmDevelopmentCommitComment>
<scmRollbackCommitComment>Release: Rollback the release of @{releaseLabel}</scmRollbackCommitComment>
<tagNameFormat>v@{project.version}</tagNameFormat>
<projectVersionPolicyId>ConventionalCommitsVersionPolicy</projectVersionPolicyId>
<projectVersionPolicyConfig>
<versionTag>^v([0-9]+\.[0-9]+\.[0-9]+)$</versionTag>
</projectVersionPolicyConfig>
<preparationProfiles>packageForRelease</preparationProfiles>
<preparationGoals>clean verify</preparationGoals>
<releaseProfiles>packageForRelease</releaseProfiles>
<pushChanges>false</pushChanges>
<remoteTagging>false</remoteTagging>
</configuration>
</plugin>
<plugin>
<groupId>org.cyclonedx</groupId>
<artifactId>cyclonedx-maven-plugin</artifactId>
<version>${cyclonedx-maven-plugin.version}</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>makeAggregateBom</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<licenses>
<license>
<name>Apache License, Version 2.0</name>
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<developers>
<developer>
<name>Niels Basjes</name>
<email>niels@basjes.nl</email>
<roles>
<role>Architect</role>
<role>Developer</role>
</roles>
<timezone>Europe/Amsterdam</timezone>
</developer>
</developers>
<scm>
<url>https://github.com/nielsbasjes/codeowners</url>
<connection>scm:git:https://github.com/nielsbasjes/codeowners.git</connection>
<developerConnection>scm:git:file:///${project.basedir}</developerConnection>
<tag>v2.0.0</tag>
</scm>
</project>