spotbugs-maven-plugin
Used in:
components
- OverviewOverview
- VersionsVersions
- DependentsDependents
- DependenciesDependencies
<dependency>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<version>4.10.3.0</version>
</dependency><?xml version="1.0" encoding="UTF-8"?>
<!--
SPDX-License-Identifier: Apache-2.0
See LICENSE file for details.
Copyright 2005-2026 the original author or authors.
-->
<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>
<parent>
<groupId>com.github.hazendaz</groupId>
<artifactId>base-parent</artifactId>
<version>60</version>
<relativePath />
</parent>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<version>4.10.3.0</version>
<packaging>maven-plugin</packaging>
<name>spotbugs-maven-plugin</name>
<description>This Plug-In generates reports based on the SpotBugs Library</description>
<url>https://spotbugs.github.io/spotbugs-maven-plugin/</url>
<inceptionYear>2005</inceptionYear>
<organization>
<name>Spotbugs</name>
<url>https://spotbugs.github.io/</url>
</organization>
<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>
<id>jlandis</id>
<name>Jeremy Landis</name>
<email>jeremylandis@hotmail.com</email>
<url>https://www.linkedin.com/in/jeremy-landis-548b2719</url>
<organization>hazendaz</organization>
<organizationUrl>https://github.com/hazendaz</organizationUrl>
<roles>
<role>Architect</role>
<role>Developer</role>
</roles>
<timezone>-5</timezone>
<properties>
<picUrl>https://avatars0.githubusercontent.com/u/975267</picUrl>
</properties>
</developer>
</developers>
<contributors>
<contributor>
<name>Jeremy Landis</name>
<email>jeremylandis@hotmail.com</email>
<url>https://www.linkedin.com/in/jeremy-landis-548b2719</url>
<organization>hazendaz</organization>
<organizationUrl>https://github.com/hazendaz</organizationUrl>
<roles>
<role>Developer</role>
</roles>
<timezone>-5</timezone>
<properties>
<picUrl>https://avatars0.githubusercontent.com/u/975267</picUrl>
</properties>
</contributor>
</contributors>
<prerequisites>
<maven>3.6.3</maven>
</prerequisites>
<scm>
<connection>scm:git:ssh://git@github.com/spotbugs/spotbugs-maven-plugin.git</connection>
<developerConnection>scm:git:ssh://git@github.com/spotbugs/spotbugs-maven-plugin.git</developerConnection>
<tag>spotbugs-maven-plugin-4.10.3.0</tag>
<url>https://github.com/spotbugs/spotbugs-maven-plugin</url>
</scm>
<issueManagement>
<system>Github</system>
<url>https://github.com/spotbugs/spotbugs-maven-plugin/issues</url>
</issueManagement>
<ciManagement>
<system>Github</system>
<url>https://github.com/spotbugs/spotbugs-maven-plugin/actions</url>
</ciManagement>
<distributionManagement>
<site>
<id>gh-pages-scm</id>
<url>scm:git:ssh://git@github.com/spotbugs/spotbugs-maven-plugin.git</url>
</site>
</distributionManagement>
<properties>
<!-- Align java runtime with spotbugs -->
<java.version>11</java.version>
<java.release.version>11</java.release.version>
<javadoc.java.release.version>11</javadoc.java.release.version>
<sourceDirectory>${project.basedir}/src/main/groovy</sourceDirectory>
<testSourceDirectory>${project.basedir}/src/test/groovy</testSourceDirectory>
<!-- Reproducible Builds: override timestamp value from parent -->
<project.build.outputTimestamp>1783904323</project.build.outputTimestamp>
<jacoco.minimum.coverage>0.54</jacoco.minimum.coverage>
<!-- Override spotbugs to this version from base-parent -->
<spotbugs.version>4.10.3</spotbugs.version>
<spotbugs.plugin>4.10.2.0</spotbugs.plugin>
<!-- Use 'master' branch or '${spotbugs.version}' tag for integration test source pull from spotbugs. -->
<spotbugs-scm.version>${spotbugs.version}</spotbugs-scm.version>
<spotbugs-scm.type>tags</spotbugs-scm.type>
<byte-buddy.version>1.18.11</byte-buddy.version>
<javabean-tester.version>2.12.2</javabean-tester.version>
<junitVersion>6.1.2</junitVersion>
<log4j2.version>2.26.1</log4j2.version>
<slf4jVersion>2.0.18</slf4jVersion>
<groovyVersion>5.0.7</groovyVersion>
<javaparserVersion>3.28.2</javaparserVersion>
<doxiaVersion>2.1.0</doxiaVersion>
<doxiaSiteToolsVersion>2.1.0</doxiaSiteToolsVersion>
<mavenSharedUtilsVersion>3.4.2</mavenSharedUtilsVersion>
<mavenReportingApiVersion>4.0.0</mavenReportingApiVersion>
<mavenReportingVersion>4.0.0</mavenReportingVersion>
<mavenVersion>3.9.16</mavenVersion>
<!-- Maven minimum version -->
<maven.min-version>${mavenVersion}</maven.min-version>
<resolver.version>1.9.27</resolver.version>
<plexusComponentAnnotationsVersion>2.2.0</plexusComponentAnnotationsVersion>
<plexusResourcesVersion>1.3.1</plexusResourcesVersion>
<plexusUtilsVersion>4.0.3</plexusUtilsVersion>
<plexusVelocityVersion>2.3.0</plexusVelocityVersion>
<plexusXmlVersion>3.0.2</plexusXmlVersion>
<download-plugin.version>2.1.0</download-plugin.version>
<execPluginVersion>3.6.3</execPluginVersion>
<find-and-replace-plugin.version>1.0.5</find-and-replace-plugin.version>
<pluginPluginVersion>3.15.2</pluginPluginVersion>
<l10nPluginVersion>1.2.0</l10nPluginVersion>
<codenarcPluginVersion>0.1</codenarcPluginVersion>
<gmavenPluginVersion>5.1.0</gmavenPluginVersion>
<spotbugsTestDebug>false</spotbugsTestDebug>
<localTestSrc>${user.dir}/SpotBugs</localTestSrc>
<remoteTestSrc>https://github.com/spotbugs/spotbugs/archive/refs/${spotbugs-scm.type}/${spotbugs-scm.version}.zip</remoteTestSrc>
<testSrc>remote</testSrc>
<!-- Tests -->
<spock.version>2.4-groovy-5.0</spock.version>
<maven-plugin-testing-harness.version>3.5.1</maven-plugin-testing-harness.version>
<!-- Used by Integration tests -->
<findsecbugs.version>1.14.0</findsecbugs.version>
<servletApiVersion>6.1.0</servletApiVersion>
<sb-contrib.version>7.6.10</sb-contrib.version>
<!-- Targeted patches -->
<asm.version>9.10.1</asm.version>
<bcel.version>6.12.0</bcel.version>
<beanutils.version>1.11.0</beanutils.version>
<codec.version>1.22.0</codec.version>
<codenarc.version>3.7.0-groovy-4.0</codenarc.version>
<collections.version>3.2.2</collections.version>
<gson.version>2.14.0</gson.version>
<inject.version>1</inject.version>
<io.version>2.22.0</io.version>
<jaxen.version>2.0.6</jaxen.version>
<lang3.version>3.20.0</lang3.version>
<logging.version>1.4.0</logging.version>
<saxon.he.version>12.10</saxon.he.version>
<velocity.version>2.4.1</velocity.version>
<!-- Automatic Module Name -->
<module.name>com.github.spotbugs.maven</module.name>
<!-- Surefire Setup -->
<argLine>-javaagent:${settings.localRepository}/net/bytebuddy/byte-buddy-agent/${byte-buddy.version}/byte-buddy-agent-${byte-buddy.version}.jar</argLine>
</properties>
<dependencyManagement>
<dependencies>
<!-- Ensure we use latest version of byte buddy and further allow argLine to properly work! -->
<dependency>
<groupId>net.bytebuddy</groupId>
<artifactId>byte-buddy</artifactId>
<version>${byte-buddy.version}</version>
</dependency>
<dependency>
<groupId>net.bytebuddy</groupId>
<artifactId>byte-buddy-agent</artifactId>
<version>${byte-buddy.version}</version>
</dependency>
<!-- Ensure we use latest version regardless of spotbugs version -->
<dependency>
<groupId>org.ow2.asm</groupId>
<artifactId>asm-bom</artifactId>
<version>${asm.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<!-- Ensure we use latest version regardless of spotbugs version -->
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-bom</artifactId>
<version>${groovyVersion}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<!-- Ensure we use latest version regardless of spotbugs version -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-bom</artifactId>
<version>${slf4jVersion}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<!-- Ensure we use latest version regardless of spotbugs version -->
<dependency>
<groupId>org.apache.bcel</groupId>
<artifactId>bcel</artifactId>
<version>${bcel.version}</version>
</dependency>
<!-- Ensure we use latest version regardless of spotbugs version -->
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>${gson.version}</version>
</dependency>
<!-- Ensure we use latest version regardless of spotbugs version -->
<dependency>
<groupId>jaxen</groupId>
<artifactId>jaxen</artifactId>
<version>${jaxen.version}</version>
</dependency>
<!-- Ensure we use latest version regardless of spotbugs version -->
<dependency>
<groupId>net.sf.saxon</groupId>
<artifactId>Saxon-HE</artifactId>
<version>${saxon.he.version}</version>
</dependency>
<!-- Commons -->
<dependency>
<groupId>commons-beanutils</groupId>
<artifactId>commons-beanutils</artifactId>
<version>${beanutils.version}</version>
</dependency>
<dependency>
<groupId>commons-codec</groupId>
<artifactId>commons-codec</artifactId>
<version>${codec.version}</version>
</dependency>
<dependency>
<groupId>commons-collections</groupId>
<artifactId>commons-collections</artifactId>
<version>${collections.version}</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>${io.version}</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>${lang3.version}</version>
</dependency>
<dependency>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
<version>${logging.version}</version>
</dependency>
<!-- Force control of reporting api -->
<dependency>
<groupId>org.apache.maven.reporting</groupId>
<artifactId>maven-reporting-api</artifactId>
<version>${mavenReportingApiVersion}</version>
</dependency>
<!-- Ensure latest maven shared utils shows up -->
<dependency>
<groupId>org.apache.maven.shared</groupId>
<artifactId>maven-shared-utils</artifactId>
<version>${mavenSharedUtilsVersion}</version>
</dependency>
<!-- Use latest velocity -->
<dependency>
<groupId>org.apache.velocity</groupId>
<artifactId>velocity-engine-core</artifactId>
<version>${velocity.version}</version>
</dependency>
<!-- Use latest doxia for maven reporting -->
<dependency>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-core</artifactId>
<version>${doxiaVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-sink-api</artifactId>
<version>${doxiaVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-site-model</artifactId>
<version>${doxiaSiteToolsVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-site-renderer</artifactId>
<version>${doxiaSiteToolsVersion}</version>
<exclusions>
<!-- We don't need doxia html (using html5) -->
<exclusion>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-module-xhtml</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-integration-tools</artifactId>
<version>${doxiaSiteToolsVersion}</version>
</dependency>
<!-- Use latest plexus component annotations -->
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-component-annotations</artifactId>
<version>${plexusComponentAnnotationsVersion}</version>
</dependency>
<!-- Use latest plexus velocity for doxia 2 -->
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-velocity</artifactId>
<version>${plexusVelocityVersion}</version>
</dependency>
<!-- Use latest plexus utils -->
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-utils</artifactId>
<version>${plexusUtilsVersion}</version>
</dependency>
<!-- Ensure plexus xml maven 3 compatibility -->
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-xml</artifactId>
<version>${plexusXmlVersion}</version>
</dependency>
<!-- Align plexus-interpolation with doxia-integration-tools requirements -->
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-interpolation</artifactId>
<version>1.29</version>
</dependency>
<!-- Align sisu with doxia-integration-tools requirements -->
<dependency>
<groupId>org.eclipse.sisu</groupId>
<artifactId>org.eclipse.sisu.plexus</artifactId>
<version>1.0.1</version>
</dependency>
<!-- Maven 4 manages org.eclipse.sisu.inject to 0.9.0.M3, but org.eclipse.sisu.plexus:0.9.0.M4 requires 0.9.0.M4 -->
<dependency>
<groupId>org.eclipse.sisu</groupId>
<artifactId>org.eclipse.sisu.inject</artifactId>
<version>1.0.1</version>
</dependency>
<dependency>
<groupId>org.junit</groupId>
<artifactId>junit-bom</artifactId>
<version>${junitVersion}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<!-- Spotbugs -->
<dependency>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs</artifactId>
<version>${spotbugs.version}</version>
<exclusions>
<!-- We neither maven uses log4j2 so exclude it as we use slf4j -->
<exclusion>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
</exclusion>
</exclusions>
</dependency>
<!-- Logging forced to slf4j due to spotbugs using log4j2 -->
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-to-slf4j</artifactId>
<version>${log4j2.version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
</dependency>
<!-- Groovy -->
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy</artifactId>
</dependency>
<!-- Groovy quirk requires compile scope so optional makes it not show up in consumer builds. -->
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-docgenerator</artifactId>
<optional>true</optional>
</dependency>
<!-- Groovy quirk requires compile scope so optional makes it not show up in consumer builds. -->
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-groovydoc</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-json</artifactId>
</dependency>
<!-- Groovy quirk requires compile scope so optional makes it not show up in consumer builds. -->
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-templates</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-xml</artifactId>
</dependency>
<!-- JavaParser -->
<dependency>
<groupId>com.github.javaparser</groupId>
<artifactId>javaparser-core</artifactId>
<version>${javaparserVersion}</version>
</dependency>
<!-- Maven -->
<dependency>
<groupId>org.apache.maven.reporting</groupId>
<artifactId>maven-reporting-impl</artifactId>
<version>${mavenReportingVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
<version>${pluginPluginVersion}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-plugin-api</artifactId>
<version>${mavenVersion}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-artifact</artifactId>
<version>${mavenVersion}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-core</artifactId>
<version>${mavenVersion}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-model</artifactId>
<version>${mavenVersion}</version>
<scope>provided</scope>
</dependency>
<!-- Resolver -->
<dependency>
<groupId>org.apache.maven.resolver</groupId>
<artifactId>maven-resolver-api</artifactId>
<version>${resolver.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>javax.inject</groupId>
<artifactId>javax.inject</artifactId>
<version>${inject.version}</version>
</dependency>
<!-- doxia -->
<dependency>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.maven.doxia</groupId>
<artifactId>doxia-sink-api</artifactId>
</dependency>
<!-- plexus -->
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-resources</artifactId>
<version>${plexusResourcesVersion}</version>
</dependency>
<dependency>
<groupId>com.github.hazendaz</groupId>
<artifactId>javabean-tester</artifactId>
<version>${javabean-tester.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.spockframework</groupId>
<artifactId>spock-core</artifactId>
<version>${spock.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.maven.plugin-testing</groupId>
<artifactId>maven-plugin-testing-harness</artifactId>
<version>${maven-plugin-testing-harness.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<defaultGoal>install</defaultGoal>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<version>${pluginPluginVersion}</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-report-plugin</artifactId>
<version>${pluginPluginVersion}</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>l10n-maven-plugin</artifactId>
<version>${l10nPluginVersion}</version>
<configuration>
<locales>
<locale>es</locale>
<locale>fr</locale>
<locale>no_NO</locale>
<locale>pt_BR</locale>
</locales>
</configuration>
</plugin>
<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<excludeFilterFile>${project.basedir}/src/main/tools/spotbugs-exclude-filters.xml</excludeFilterFile>
</configuration>
</plugin>
<plugin>
<groupId>com.mycila</groupId>
<artifactId>license-maven-plugin</artifactId>
<configuration>
<licenseSets>
<licenseSet>
<excludes combine.children="append">
<exclude>**/*edu.umd.cs.findbugs.core.prefs</exclude>
<exclude>**/*.txt</exclude>
</excludes>
</licenseSet>
</licenseSets>
<mapping>
<bsh>SLASHSTAR_STYLE</bsh>
</mapping>
</configuration>
</plugin>
<plugin>
<groupId>io.github.crizzis</groupId>
<artifactId>codenarc-maven-plugin</artifactId>
<version>${codenarcPluginVersion}</version>
<configuration>
<maxPriority1Violations>0</maxPriority1Violations>
<maxPriority2Violations>0</maxPriority2Violations>
<maxPriority3Violations>0</maxPriority3Violations>
</configuration>
<dependencies>
<dependency>
<groupId>org.codenarc</groupId>
<artifactId>CodeNarc</artifactId>
<version>${codenarc.version}</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<configuration>
<attributes>
<spotbugsVersion>${spotbugs.version}</spotbugsVersion>
</attributes>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<executions>
<execution>
<id>add-stubfixer-sources</id>
<goals>
<goal>add-source</goal>
</goals>
<phase>generate-sources</phase>
<configuration>
<sources>
<source>${project.basedir}/src/stubfixer/java</source>
</sources>
</configuration>
</execution>
</executions>
</plugin>
<!-- Compile stubfixer. -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<executions>
<execution>
<id>compile-stubfixer</id>
<goals>
<goal>compile</goal>
</goals>
<phase>generate-sources</phase>
<configuration>
<compileSourceRoots>
<compileSourceRoot>${project.basedir}/src/stubfixer/java</compileSourceRoot>
</compileSourceRoots>
<outputDirectory>${project.build.directory}/classes</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<executions>
<execution>
<id>default-descriptor</id>
<goals>
<goal>descriptor</goal>
</goals>
<phase>process-classes</phase>
</execution>
<!-- Generate help goal -->
<execution>
<id>help-goal</id>
<goals>
<goal>helpmojo</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.gmavenplus</groupId>
<artifactId>gmavenplus-plugin</artifactId>
<version>${gmavenPluginVersion}</version>
<configuration>
<attachGroovyDocAnnotation>true</attachGroovyDocAnnotation>
<docTitle>${project.name} Groovy Documentation</docTitle>
<groovyDocOutputDirectory>${project.reporting.outputDirectory}/gapidocs</groovyDocOutputDirectory>
<testGroovyDocOutputDirectory>${project.reporting.outputDirectory}/testgapidocs</testGroovyDocOutputDirectory>
<footer>${project.name} Groovy Documentation</footer>
<header>${project.name} Groovy Documentation</header>
</configuration>
<dependencies>
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy</artifactId>
<version>${groovyVersion}</version>
</dependency>
</dependencies>
<executions>
<execution>
<id>compileGroovy</id>
<goals>
<goal>addSources</goal>
<goal>addTestSources</goal>
<goal>generateStubs</goal>
<goal>compile</goal>
<goal>generateTestStubs</goal>
<goal>compileTests</goal>
<goal>removeStubs</goal>
<goal>removeTestStubs</goal>
</goals>
</execution>
<execution>
<id>generate-groovydoc</id>
<goals>
<goal>groovydoc</goal>
<goal>groovydocTests</goal>
</goals>
<phase>prepare-package</phase>
</execution>
<execution>
<id>site</id>
<goals>
<goal>generateStubs</goal>
<goal>generateTestStubs</goal>
<goal>groovydoc</goal>
<goal>groovydocTests</goal>
</goals>
<phase>site</phase>
</execution>
</executions>
</plugin>
<!-- Strip non-reproducible timestamps from GroovyDoc HTML before JAR packaging -->
<!-- Exists until https://github.com/groovy/GMavenPlus/issues/342 is resolved -->
<plugin>
<groupId>software.xdev</groupId>
<artifactId>find-and-replace-maven-plugin</artifactId>
<version>${find-and-replace-plugin.version}</version>
<executions>
<execution>
<id>strip-groovydoc-comment-timestamps</id>
<goals>
<goal>file-contents</goal>
</goals>
<phase>prepare-package</phase>
<configuration>
<baseDir>${project.reporting.outputDirectory}</baseDir>
<recursive>true</recursive>
<fileMask>.html</fileMask>
<findRegex>on \w+ \w+ +\d+ \d+:\d+:\d+ \S+ \d+</findRegex>
<replaceValue />
</configuration>
</execution>
<execution>
<id>strip-groovydoc-meta-date-tags</id>
<goals>
<goal>file-contents</goal>
</goals>
<phase>prepare-package</phase>
<configuration>
<baseDir>${project.reporting.outputDirectory}</baseDir>
<recursive>true</recursive>
<fileMask>.html</fileMask>
<findRegex><meta name="date" content="[0-9-]+"\></findRegex>
<replaceValue />
</configuration>
</execution>
</executions>
</plugin>
<!-- Add missing @Override to stubs fixing codeql issues that groovy doesn't care about. -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
<version>${execPluginVersion}</version>
<executions>
<execution>
<id>run-stubfixer-main</id>
<goals>
<goal>java</goal>
</goals>
<phase>generate-sources</phase>
<configuration>
<mainClass>com.github.spotbugs.StubOverrideFixer</mainClass>
<classpathScope>compile</classpathScope>
<arguments>
<argument>${project.build.directory}/generated-sources/groovy-stubs/main</argument>
</arguments>
</configuration>
</execution>
<execution>
<id>run-stubfixer-test</id>
<goals>
<goal>java</goal>
</goals>
<phase>generate-test-sources</phase>
<configuration>
<mainClass>com.github.spotbugs.StubOverrideFixer</mainClass>
<classpathScope>compile</classpathScope>
<arguments>
<argument>${project.build.directory}/generated-sources/groovy-stubs/test</argument>
</arguments>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<executions>
<execution>
<id>package-reproducible-groovydoc-jar</id>
<goals>
<goal>jar</goal>
</goals>
<phase>package</phase>
<configuration>
<classifier>groovydoc</classifier>
<classesDirectory>${project.build.directory}/site/gapidocs</classesDirectory>
<skipIfEmpty>true</skipIfEmpty>
</configuration>
</execution>
<execution>
<id>package-reproducible-test-groovydoc-jar</id>
<goals>
<goal>jar</goal>
</goals>
<phase>package</phase>
<configuration>
<classifier>test-groovydoc</classifier>
<classesDirectory>${project.build.directory}/site/testgapidocs</classesDirectory>
<skipIfEmpty>true</skipIfEmpty>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>io.github.crizzis</groupId>
<artifactId>codenarc-maven-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<executions>
<execution>
<id>check</id>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.openrewrite.maven</groupId>
<artifactId>rewrite-maven-plugin</artifactId>
<configuration>
<exclusions>
<!-- Open rewrite cannot handle non packaged groovy files used by maven invoker. -->
<exclusion>**/*verify.groovy</exclusion>
<!-- Open rewrite cannot handle groovy traits. -->
<exclusion>**/*SpotBugsPluginsTrait.groovy</exclusion>
</exclusions>
</configuration>
</plugin>
<plugin>
<groupId>net.revelc.code.formatter</groupId>
<artifactId>formatter-maven-plugin</artifactId>
<executions>
<execution>
<id>process-test-sources</id>
<goals>
<goal>format</goal>
</goals>
<phase>process-test-sources</phase>
</execution>
</executions>
</plugin>
</plugins>
</build>
<reporting>
<excludeDefaults>true</excludeDefaults>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-report-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>l10n-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>io.github.crizzis</groupId>
<artifactId>codenarc-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
</plugin>
</plugins>
</reporting>
<profiles>
<profile>
<id>eclipse</id>
<activation>
<property>
<name>m2e.version</name>
</property>
</activation>
<build>
<pluginManagement>
<plugins>
<!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<!-- Keep version here as fake version and maven report info has problems defining it in dependency management -->
<version>${lifecycle.plugin}</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions combine.children="append">
<!-- Ignore gmavenplus in m2e -->
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.codehaus.gmavenplus</groupId>
<artifactId>gmavenplus-plugin</artifactId>
<versionRange>[${gmavenPluginVersion},)</versionRange>
<goals>
<goal>addSources</goal>
<goal>addTestSources</goal>
<goal>generateStubs</goal>
<goal>compile</goal>
<goal>generateTestStubs</goal>
<goal>compileTests</goal>
<goal>removeStubs</goal>
<goal>removeTestStubs</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
<!-- Ignore exec maven plugin in m2e -->
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>exec-maven-plugin</artifactId>
<versionRange>[${execPluginVersion},)</versionRange>
<goals>
<goal>java</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
</profile>
<profile>
<id>run-its</id>
<properties>
<spotbug.debug>false</spotbug.debug>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<executions>
<execution>
<id>strip-unnecessary-test-cases</id>
<goals>
<goal>clean</goal>
</goals>
<phase>integration-test</phase>
<configuration>
<excludeDefaultDirectories>true</excludeDefaultDirectories>
<filesets>
<fileset>
<directory>${project.build.directory}/spotbugs-${spotbugs-scm.version}</directory>
<includes>
<include>**/*</include>
</includes>
<excludes>
<exclude>**/spotbugsTestCases/src/java/A*.java</exclude>
<exclude>**/spotbugsTestCases/src/java/Use*.java</exclude>
<exclude>**/spotbugsTestCases/src/java/annotations/*.java</exclude>
</excludes>
<followSymlinks>false</followSymlinks>
</fileset>
</filesets>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-invoker-plugin</artifactId>
<dependencies>
<!-- Keep groovy at same version we are using -->
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy</artifactId>
<version>${groovyVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-json</artifactId>
<version>${groovyVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-nio</artifactId>
<version>${groovyVersion}</version>
</dependency>
<dependency>
<groupId>org.apache.groovy</groupId>
<artifactId>groovy-xml</artifactId>
<version>${groovyVersion}</version>
</dependency>
</dependencies>
<executions>
<execution>
<!--Package test include and exclude files and file local repo -->
<id>prepare-integration-test</id>
<goals>
<goal>install</goal>
<goal>run</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<parallelThreads>1</parallelThreads>
<projectsDirectory>${project.basedir}/src/it-tools</projectsDirectory>
<cloneProjectsTo>${project.build.directory}/it</cloneProjectsTo>
<showVersion>true</showVersion>
<pomIncludes>
<pomInclude>*/pom.xml</pomInclude>
</pomIncludes>
<postBuildHookScript>verify</postBuildHookScript>
<localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
<goals>
<goal>install</goal>
</goals>
<settingsFile>${project.basedir}/src/it/settings.xml</settingsFile>
<streamLogsOnFailures>true</streamLogsOnFailures>
</configuration>
</execution>
<execution>
<id>integration-test-run</id>
<goals>
<goal>run</goal>
</goals>
<configuration>
<projectsDirectory>${project.basedir}/src/it</projectsDirectory>
<cloneProjectsTo>${project.build.directory}/it</cloneProjectsTo>
<filterProperties>
<java.specification.version>${java.specification.version}</java.specification.version>
</filterProperties>
<showVersion>true</showVersion>
<pomIncludes>
<pomInclude>*/pom.xml</pomInclude>
</pomIncludes>
<postBuildHookScript>verify</postBuildHookScript>
<localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
<settingsFile>${project.basedir}/src/it/settings.xml</settingsFile>
<streamLogsOnFailures>true</streamLogsOnFailures>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>spot-it-src-checkout</id>
<activation>
<property>
<name>testSrc</name>
<value>remote</value>
</property>
</activation>
<build>
<plugins>
<plugin>
<groupId>io.github.download-maven-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<executions>
<execution>
<id>prepare-integration-test-remote-spotbugs-src</id>
<goals>
<goal>wget</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<alwaysVerifyChecksum>false</alwaysVerifyChecksum>
<outputDirectory>${project.build.directory}</outputDirectory>
<overwrite>true</overwrite>
<url>${remoteTestSrc}</url>
<unpack>true</unpack>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>spot-it-src-local</id>
<activation>
<property>
<name>testSrc</name>
<value>local</value>
</property>
</activation>
<properties>
<spotbugs-scm.version>local</spotbugs-scm.version>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<executions>
<execution>
<id>prepare-integration-test-local-spotbugs-src</id>
<goals>
<goal>copy-resources</goal>
</goals>
<phase>pre-integration-test</phase>
<configuration>
<outputDirectory>${project.build.directory}/spotbugs-${spotbugs-scm.version}</outputDirectory>
<resources>
<resource>
<directory>${localTestSrc}</directory>
<filtering>false</filtering>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>maven4</id>
<activation>
<property>
<name>maven.version</name>
<value>4.0.0-rc-5</value>
</property>
</activation>
<build>
<plugins>
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>compile-stubfixer-main</id>
<goals>
<goal>run</goal>
</goals>
<phase>generate-sources</phase>
<configuration>
<target>
<mkdir dir="${project.build.outputDirectory}" />
<javac classpathref="maven.compile.classpath" destdir="${project.build.outputDirectory}" encoding="${project.build.sourceEncoding}" includeantruntime="false" release="${java.release.version}" srcdir="${project.basedir}/src/stubfixer/java" />
</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.gmavenplus</groupId>
<artifactId>gmavenplus-plugin</artifactId>
<!-- gmavenplus reads maven.compiler.target for targetBytecode; base-parent's Maven 4 profile clears
maven.compiler.source/target to avoid compiler-plugin 4.x conflicts, so set targetBytecode
directly to keep Groovy compilation aligned with the configured Java release. -->
<configuration>
<targetBytecode>${java.release.version}</targetBytecode>
</configuration>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>