Skip to content

Commit

Permalink
build: add maven-enforcer-plugin with many rules
Browse files Browse the repository at this point in the history
  • Loading branch information
NiccoMlt committed Oct 18, 2024
1 parent 0539afd commit 154e1b2
Show file tree
Hide file tree
Showing 3 changed files with 49 additions and 13 deletions.
11 changes: 6 additions & 5 deletions carapace-server/pom.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"
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>
Expand Down Expand Up @@ -196,14 +197,14 @@
<groupId>org.checkerframework</groupId>
<artifactId>checker-qual</artifactId>
</exclusion>
<exclusion>
<groupId>com.google.errorprone</groupId>
<artifactId>error_prone_annotations</artifactId>
</exclusion>
<exclusion>
<groupId>com.google.code.findbugs</groupId>
<artifactId>jsr305</artifactId>
</exclusion>
<exclusion>
<groupId>com.google.errorprone</groupId>
<artifactId>error_prone_annotations</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
Expand Down
3 changes: 2 additions & 1 deletion carapace-ui/pom.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"
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>
Expand Down
48 changes: 41 additions & 7 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@
<libs.mockito>3.12.4</libs.mockito>
<libs.hamcrest>2.2</libs.hamcrest>

<plugins.spotbugsmaven>4.5.3.0</plugins.spotbugsmaven>
<libs.asm>9.2</libs.asm>
</properties>

Expand Down Expand Up @@ -299,7 +298,7 @@
<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<version>${plugins.spotbugsmaven}</version>
<version>4.8.6.4</version>
<configuration>
<effort>Max</effort>
<maxHeap>4096</maxHeap>
Expand All @@ -316,7 +315,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.2.5</version>
<version>3.5.1</version>
<configuration>
<reuseForks>false</reuseForks>
<trimStackTrace>false</trimStackTrace>
Expand Down Expand Up @@ -352,7 +351,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.6.1</version>
<version>3.8.0</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
Expand All @@ -362,7 +361,37 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<version>3.6.0</version>
<version>3.7.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<version>3.4.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<version>3.1.3</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<version>3.20.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>
<version>3.1.3</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>3.3.1</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>3.4.2</version>
</plugin>
</plugins>
</pluginManagement>
Expand All @@ -375,7 +404,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>3.0.1</version>
<version>3.1.1</version>
<configuration>
<preparationProfiles>production</preparationProfiles>
<releaseProfiles>production</releaseProfiles>
Expand All @@ -401,12 +430,12 @@
<configuration>
<rules>
<banDependencyManagementScope/>
<banDuplicatePomDependencyVersions/>
<banDynamicVersions>
<ignores>
<ignore>${project.groupId}</ignore>
</ignores>
</banDynamicVersions>
<banDuplicatePomDependencyVersions/>
<bannedDependencies>
<excludes>
<exclude>com.google.errorprone</exclude>
Expand All @@ -418,6 +447,11 @@
<include>org.bouncycastle:*-jdk15on</include>
</includes>
</bannedDependencies>
<dependencyConvergence/>
<requireMavenVersion>
<version>3.9</version>
</requireMavenVersion>
<requirePluginVersions/>
</rules>
</configuration>
</execution>
Expand Down

0 comments on commit 154e1b2

Please sign in to comment.