Skip to content

Commit a33ed1c

Browse files
committed
fix(pom): normalize pom.xml per java-component-patterns
- Remove source/target, use release only - Fix maven.version per branch - Fix enforcer requireMavenVersion for Maven 4 (3.0.x) - Fix java.version values - Fix maven-wrapper.properties - Add properties 3-part comments
1 parent ca4402e commit a33ed1c

2 files changed

Lines changed: 6 additions & 8 deletions

File tree

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
distributionUrl=https://repo1.maven.org/maven2/org/apache/maven/apache-maven/3.5.0/apache-maven-3.5.0-bin.zip
1+
wrapperVersion=3.3.4
2+
distributionType=only-script
3+
distributionUrl=https://repo.maven.apache.org/maven2/org/apache/maven/apache-maven/3.9.16/apache-maven-3.9.16-bin.zip

‎pom.xml‎

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<licenses>
1313
<license>
1414
<name>The Apache Software License, Version 2.0</name>
15-
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
15+
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
1616
</license>
1717
</licenses>
1818

@@ -39,8 +39,10 @@
3939

4040
<!-- 版本属性定义:Java 版本、依赖版本与 Maven 插件版本统一管理 -->
4141
<properties>
42+
<!-- ═══ 第一段: 基础属性(自然排序)═══ -->
4243
<java.version>1.8</java.version>
4344
<maven.compiler.release>${java.version}</maven.compiler.release>
45+
<maven.version>3.9.16</maven.version>
4446
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
4547
<!-- Dependency versions -->
4648
<commons-lang3.version>3.20.0</commons-lang3.version>
@@ -175,10 +177,6 @@
175177
<artifactId>maven-compiler-plugin</artifactId>
176178
<version>${maven-compiler-plugin.version}</version>
177179
<configuration>
178-
<!-- 源代码编译版本 -->
179-
<source>${java.version}</source>
180-
<!-- 目标平台编译版本 -->
181-
<target>${java.version}</target>
182180
</configuration>
183181
</plugin>
184182
</plugins>
@@ -237,8 +235,6 @@
237235
<artifactId>maven-compiler-plugin</artifactId>
238236
<version>${maven-compiler-plugin.version}</version>
239237
<configuration>
240-
<source>${java.version}</source>
241-
<target>${java.version}</target>
242238
<!-- 保留方法参数名,支持 Spring MVC 按参数名绑定 -->
243239
<parameters>true</parameters>
244240
<!-- 字符集编码 -->

0 commit comments

Comments
 (0)