mirror of
https://github.com/actions/setup-java.git
synced 2026-08-06 05:39:28 +08:00
955f34f16f
* Add JDK caching Cache resolved JDK tool-cache entries by exact platform and release identity, with a default-on cache-jdk input and explicit opt-out. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Apply batched suggestions from code review Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> * Fix JDK cache CI validation Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Update brace-expansion security fix Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Refresh brace-expansion license metadata Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Refine JDK cache semantics Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Refine JDK cache documentation Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Simplify JDK cache identity Use one normalized runner OS dimension, reset the internal cache key schema for the unreleased feature, and align documentation, tests, and bundles. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Align JDK cache OS identity Use the established RUNNER_OS value directly and retain process.platform only as a non-Actions fallback. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Harden JDK cache saves and document tool-cache reuse Bind each JDK cache key to the installation identity it was computed for, keep post-job saves best-effort per entry, and state the real reuse and verification guarantee in the documentation. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * docs: restructure README caching section Rename '## Caching dependencies' to '## Caching' and add a what-gets-cached overview table covering the dependency, wrapper, and JDK caches. Lead with the common 'cache: maven' example and the dependency-cache material, and demote JDK caching into its own subsection. Also corrects the IMPORTANT callout, which implied JDK caching required an explicit opt-in; it is enabled implicitly whenever 'cache' is set. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * docs: fix caching documentation defects - Remove pull-request framing that compared behavior to `main`; state the tool-cache and `jdkfile` behavior directly and unconditionally. - Clarify that the JDK cache is a separate cache *entry* from the dependency and wrapper caches, while its *enablement* is coupled to `cache`, so the opening paragraph agrees with the enablement matrix. - Cite the actions/setup-java-benchmarks repository instead of an open PR and a self-referential PR comment, keeping the measured figures and caveats. - Keep the `cache`/`cache-jdk` matrix only in docs/advanced-usage.md and summarize the rules in prose in README.md to avoid divergence. - Describe the guarantee that a cache key is only saved with the installation it was computed for, instead of documenting inode/size/timestamp internals. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * docs: add V6 what's new entry for JDK caching Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: e2755464-4e83-47b6-ba71-731bb481b418 --------- Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com> Copilot-Session: e2755464-4e83-47b6-ba71-731bb481b418
87 lines
2.6 KiB
JSON
87 lines
2.6 KiB
JSON
{
|
|
"name": "setup-java",
|
|
"version": "6.0.0",
|
|
"type": "module",
|
|
"private": true,
|
|
"description": "setup java action",
|
|
"main": "dist/setup/index.js",
|
|
"engines": {
|
|
"node": ">=24.0.0"
|
|
},
|
|
"scripts": {
|
|
"build": "node scripts/patch-is-unsafe.mjs && ncc build -o dist/setup src/setup-java.ts && ncc build -o dist/cleanup src/cleanup-java.ts",
|
|
"format": "prettier --no-error-on-unmatched-pattern --write \"**/*.{ts,yml,yaml}\"",
|
|
"format-check": "prettier --no-error-on-unmatched-pattern --check \"**/*.{ts,yml,yaml}\"",
|
|
"lint": "eslint \"**/*.ts\"",
|
|
"lint:fix": "eslint \"**/*.ts\" --fix",
|
|
"check": "npm run format-check && npm run lint && npm run build && npm test",
|
|
"fix": "npm run format && npm run lint:fix && npm run build",
|
|
"prepare": "husky install",
|
|
"prerelease": "npm run-script build",
|
|
"release": "git add -f dist/setup/*.js dist/setup/package.json dist/cleanup/*.js",
|
|
"test": "node --experimental-vm-modules ./node_modules/jest/bin/jest.js --runInBand --coverage"
|
|
},
|
|
"lint-staged": {
|
|
"*.ts": [
|
|
"prettier --no-error-on-unmatched-pattern --write",
|
|
"eslint --fix"
|
|
],
|
|
"*.{yml,yaml}": [
|
|
"prettier --no-error-on-unmatched-pattern --write"
|
|
]
|
|
},
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "git+https://github.com/actions/setup-java.git"
|
|
},
|
|
"keywords": [
|
|
"actions",
|
|
"java",
|
|
"setup"
|
|
],
|
|
"author": "GitHub",
|
|
"license": "MIT",
|
|
"dependencies": {
|
|
"@actions/cache": "^6.2.0",
|
|
"@actions/core": "^3.0.1",
|
|
"@actions/exec": "^3.0.0",
|
|
"@actions/glob": "^0.7.0",
|
|
"@actions/http-client": "^4.0.1",
|
|
"@actions/io": "^3.0.2",
|
|
"@actions/tool-cache": "^4.0.0",
|
|
"fast-xml-parser": "^5.10.1",
|
|
"semver": "^7.8.5"
|
|
},
|
|
"devDependencies": {
|
|
"@eslint/js": "^10.0.1",
|
|
"@jest/globals": "^30.4.1",
|
|
"@types/node": "^26.1.1",
|
|
"@types/semver": "^7.7.0",
|
|
"@typescript-eslint/eslint-plugin": "^8.64.0",
|
|
"@typescript-eslint/parser": "^8.65.0",
|
|
"@vercel/ncc": "^0.44.0",
|
|
"eslint": "^10.7.0",
|
|
"eslint-config-prettier": "^10.1.8",
|
|
"eslint-plugin-jest": "^29.15.4",
|
|
"eslint-plugin-n": "^18.2.2",
|
|
"globals": "^17.7.0",
|
|
"husky": "^9.1.7",
|
|
"jest": "^30.4.2",
|
|
"lint-staged": "^17.2.0",
|
|
"prettier": "^3.9.5",
|
|
"ts-jest": "^29.4.11",
|
|
"typescript": "^6.0.3"
|
|
},
|
|
"bugs": {
|
|
"url": "https://github.com/actions/setup-java/issues"
|
|
},
|
|
"homepage": "https://github.com/actions/setup-java#readme",
|
|
"overrides": {
|
|
"@actions/cache": {
|
|
"@actions/glob": "0.7.0"
|
|
},
|
|
"glob": "^11.1.0",
|
|
"test-exclude": "^7.0.2"
|
|
}
|
|
}
|