update build time

This commit is contained in:
thinkgem
2023-07-30 20:09:04 +08:00
parent ae17e2c2a4
commit fce22831ab

View File

@@ -104,6 +104,12 @@
<artifactId>maven-resources-plugin</artifactId>
</plugin>
<!-- timestamp插件 -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
</plugin>
</plugins>
<pluginManagement>
@@ -125,6 +131,25 @@
</configuration>
</plugin>
<!-- timestamp插件生成编译时间 -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<executions>
<execution>
<id>timestamp-property</id>
<goals>
<goal>timestamp-property</goal>
</goals>
<configuration>
<name>build.time</name>
<pattern>yyyy-MM-dd HH:mm</pattern>
<timeZone>GMT+8</timeZone>
</configuration>
</execution>
</executions>
</plugin>
<!-- jar插件配置manifest文件加入lib包的jar依赖 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
@@ -139,7 +164,7 @@
</manifest>
<addMavenDescriptor>false</addMavenDescriptor>
<manifestEntries>
<Build-Time>${maven.build.timestamp}</Build-Time>
<Build-Time>${build.time}</Build-Time>
</manifestEntries>
</archive>
</configuration>
@@ -182,7 +207,7 @@
</manifest>
<addMavenDescriptor>false</addMavenDescriptor>
<manifestEntries>
<Build-Time>${maven.build.timestamp}</Build-Time>
<Build-Time>${build.time}</Build-Time>
</manifestEntries>
</archive>
</configuration>