💚 Reuse npm cache in publish job
The publish job ran npm ci against a cold cache on every release while build/maintain already share a warm node-cache key off the same lockfile. Tag runs can read caches saved on main, so wiring cache: npm here is free.
This commit is contained in:
1 parent
5292455dbc
commit
b9fe21175f
1 file changed
+4
@@ -139,6 +139,10 @@ jobs:
|
|||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version-file: .node-version
|
node-version-file: .node-version
|
||||||
|
# Same lockfile/key as `build`, and tag runs can read caches
|
||||||
|
# saved on `main` — without this, every release pays a cold
|
||||||
|
# `npm ci` despite the warm shared npm cache.
|
||||||
|
cache: "npm"
|
||||||
registry-url: "https://registry.npmjs.org/"
|
registry-url: "https://registry.npmjs.org/"
|
||||||
- run: npm ci
|
- run: npm ci
|
||||||
# Consume the dist/ that `build` produced and gated, instead of
|
# Consume the dist/ that `build` produced and gated, instead of
|
||||||
|
|||||||
Reference in new issue
Block a user