-
Notifications
You must be signed in to change notification settings - Fork 128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: make pom.xml reproducible #150
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -51,6 +51,7 @@ | |
<maven.build.timestamp.format>yyyyMMdd.HHmmss</maven.build.timestamp.format> | ||
<javafx.version>19.0.2.1</javafx.version> | ||
<maven.compiler.release>11</maven.compiler.release> | ||
<project.build.outputTimestamp>2023-01-01T00:00:00Z</project.build.outputTimestamp> | ||
</properties> | ||
|
||
<issueManagement> | ||
|
@@ -166,7 +167,7 @@ | |
</dependency> | ||
</dependencies> | ||
<build> | ||
<finalName>${project.artifactId}-${project.version}-${maven.build.timestamp}</finalName> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd like to leave it as is. If you want shorter name please rename it after build using your-OS packaging tools. |
||
<finalName>${project.artifactId}-${project.version}</finalName> | ||
<resources> | ||
<resource> | ||
<directory>src/main/resources</directory> | ||
|
@@ -193,26 +194,51 @@ | |
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-surefire-plugin</artifactId> | ||
<version>2.22.2</version> | ||
<version>3.1.2</version> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-failsafe-plugin</artifactId> | ||
<version>2.22.2</version> | ||
<version>3.1.2</version> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-compiler-plugin</artifactId> | ||
<version>3.10.1</version> | ||
<version>3.11.0</version> | ||
<configuration> | ||
<release>11</release> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-enforcer-plugin</artifactId> | ||
<version>3.3.0</version> | ||
<executions> | ||
<execution> | ||
<id>enforce-versions</id> | ||
<phase>validate</phase> | ||
<goals> | ||
<goal>enforce</goal> | ||
</goals> | ||
<configuration> | ||
<rules> | ||
<requireMavenVersion> | ||
<version>[3.2.5,)</version> | ||
</requireMavenVersion> | ||
<requireJavaVersion> | ||
<version>[1.8,)</version> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Minimal runtime is '11', not '1.8' per line 53 |
||
</requireJavaVersion> | ||
<requirePluginVersions /> | ||
</rules> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
<!-- Don't generate default JAR without dependencies --> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-jar-plugin</artifactId> | ||
<version>3.1.2</version> | ||
<version>3.3.0</version> | ||
<!-- | ||
<configuration> | ||
<manifestEntries> | ||
|
@@ -231,7 +257,7 @@ | |
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-assembly-plugin</artifactId> | ||
<version>3.1.0</version> | ||
<version>3.6.0</version> | ||
<configuration> | ||
<archive> | ||
<manifest> | ||
|
@@ -255,7 +281,7 @@ | |
</plugin> | ||
<plugin> | ||
<groupId>com.akathist.maven.plugins.launch4j</groupId> | ||
<version>2.2.0</version> | ||
<version>2.4.1</version> | ||
<artifactId>launch4j-maven-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
|
@@ -268,7 +294,7 @@ | |
<headerType>gui</headerType> | ||
<icon>appicon.ico</icon> | ||
<outfile>target/${project.name}.exe</outfile> | ||
<jar>target/${project.artifactId}-${project.version}-${maven.build.timestamp}.jar</jar> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please leave it as is |
||
<jar>target/${project.artifactId}-${project.version}.jar</jar> | ||
<!-- <downloadUrl>https://download.oracle.com/java/17/archive/jdk-17.0.1_windows-x64_bin.msi</downloadUrl> --> | ||
<errTitle>Launching error</errTitle> | ||
<!-- <dontWrapJar>true</dontWrapJar> --> | ||
|
@@ -298,6 +324,31 @@ | |
</execution> | ||
</executions> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-deploy-plugin</artifactId> | ||
<version>3.1.1</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-site-plugin</artifactId> | ||
<version>4.0.0-M9</version> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-install-plugin</artifactId> | ||
<version>3.1.1</version> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-clean-plugin</artifactId> | ||
<version>3.3.1</version> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
</project> | ||
</project> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's fine. In future maybe it's better to use git commits? Like article says:
"instead of explicitely writing a timestamp in their pom.xml, some people tend to prefer using last Git commit timestamp, like ${git.commit.time} from git-commit-id-maven-plugin."
Anyway, it's fine to leave as is if you think it's needed