| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
There was a problem hiding this comment.
This pull request adds an opt-in jmod input to support installing Temurin JDKs with JMOD files (needed because Temurin JDK 24+ no longer includes JMODs in the default JDK archive). It extends the Temurin installer to optionally download the matching Adoptium “jmods” artifact, merge it into the installed JDK, and cache that JDK separately.
Changes:
| File | Description |
|---|---|
| src/setup-java.ts | Reads jmod input and passes it through installer options. |
| src/distributions/temurin/installer.ts | Implements optional JMOD download/merge and toolcache folder suffixing. |
| src/distributions/base-models.ts | Adds optional jmod?: boolean to installer options model. |
| src/constants.ts | Adds INPUT_JMOD constant. |
| action.yml | Exposes jmod as a supported action input. |
| docs/advanced-usage.md | Documents jmod: true usage for Temurin. |
| tests/distributors/temurin-installer.test.ts | Adds tests for image_type=jmods, toolcache folder naming, and JMOD merge path. |
| dist/setup/index.js | Updates compiled distribution output for setup action. |
| dist/cleanup/index.js | Updates compiled distribution output for cleanup action constants. |
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Sorry, something went wrong.
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: e7d8c581-2d14-4ccc-aeca-afc0f3b0c2bc
Use platform-aware path construction for the JMOD copy and cache assertions so the Windows test expects backslash-normalized paths. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
src/distributions/temurin/installer.ts:180
Copy the jmods directory from within the extracted artifact (and account for macOS Contents/Home) instead of copying the artifact root.
const jmodsDirectory = path.join(
extractedJmodsPath,
fs.readdirSync(extractedJmodsPath)[0]
);
fs.cpSync(jmodsDirectory, path.join(javaHome, 'jmods'), {recursive: true});
tests/distributors/temurin-installer.test.ts:520
);
expect(spyCopySync).toHaveBeenCalledWith(
path.join('/tmp/extracted-jmods', 'jdk-25-jmods'),
process.platform === 'darwin'
? path.join('/tmp/extracted', 'jdk-25', 'Contents', 'Home', 'jmods')
: path.join('/tmp/extracted', 'jdk-25', 'jmods'),
{recursive: true}
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Description:
Temurin JDK 24+ excludes JMOD files from its default archive. This adds opt-in installation of Adoptium's matching JMOD artifact through the existing java-package input.
Related issue:
#804
Check list: