Skip to content

Commit 447f104

Browse files
committed
fix(build): always run npm ci, drop the lockfile-timestamp gate
The previous "only reinstall when the lockfile is newer than node_modules/.package-lock.json" check was overengineered: `npm ci` is itself the right tool for this (it's idempotent w.r.t. the lockfile and fast on warm caches with `--prefer-offline`). Just run it every time and let npm decide.
1 parent 6155ffc commit 447f104

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

scripts/compile-spec.sh

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,6 @@ set -eu
77

88
cd "$(dirname "$0")/.."/spec
99

10-
# Reinstall when node_modules is missing OR the lockfile is newer than
11-
# the install marker (renovate bumps shouldn't be silently ignored).
12-
if [ ! -d node_modules ] || [ package-lock.json -nt node_modules/.package-lock.json ]; then
13-
npm ci --prefer-offline --no-audit --no-fund
14-
fi
10+
npm ci --prefer-offline --no-audit --no-fund
1511

1612
npx tsp compile .

0 commit comments

Comments
 (0)