feat: added template for java binary builder #2
+108
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR introduces a JavaBinaryBuilder plugin following the same patterns and lifecycle as the existing
GoBinaryBuilder.The goal is to support Java repositories by producing a versioned
.jarartifact that can be uploaded to GitHub Releases in a consistent way.Currently implemented things
Auto-detect build system: Maven (
pom.xml) or Gradle (build.gradle/build.gradle.kts)JAR is the standard packaged output for Java projects and is the closest equivalent “release artifact” for this builder system, so the “binary” for Java is treated as a JAR (not a native ELF executable).
Builds are executed inside Docker containers using the repo mounted into
/app, as it ensures reproducible builds across dev machines + CI environments and follows the same execution model as theGo builder.the default Docker image is
Maven + Temurin JDK 17as Java 17 is a stable LTS choice and Maven is common. see: https://hub.docker.com/layers/library/maven/3.9-eclipse-temurin-17/images/sha256-078164c49b664077cd330ad6cd367eb3baa5188380d68c82bf364c04c11748e9Questions before i finalize the PR
So, Once the above decisions are confirmed, I will update the builder into a finalized implementation and push the changes.
PS, I havent yet manually tested this on a java project, but will do thst once the code is ready.
cc @pleia2 @rposts