Skip to content

Commit

Permalink
Merge branch 'main' into release-3.6.
Browse files Browse the repository at this point in the history
  • Loading branch information
benjamn committed Nov 16, 2021
2 parents 8baa5fa + 8155890 commit 2c28234
Show file tree
Hide file tree
Showing 28 changed files with 5,711 additions and 11,127 deletions.
2 changes: 2 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ jobs:
- image: circleci/node:16.13.0
steps:
- checkout
- run: npm run ci:precheck
- restore_cache:
keys:
# When lock file changes, use increasingly general patterns to
Expand All @@ -29,6 +30,7 @@ jobs:
- image: circleci/node:16.13.0
steps:
- checkout
- run: npm run ci:precheck
- restore_cache:
keys:
# When lock file changes, use increasingly general patterns to
Expand Down
21 changes: 21 additions & 0 deletions config/precheck.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
const {
lockfileVersion,
} = require("../package-lock.json");

const expectedVersion = 2;

if (typeof lockfileVersion !== "number" ||
lockfileVersion < expectedVersion) {
throw new Error(
`Old lockfileVersion (${
lockfileVersion
}) found in package-lock.json (expected ${
expectedVersion
} or later)`
);
}

console.log("ok", {
lockfileVersion,
expectedVersion,
});
Loading

0 comments on commit 2c28234

Please sign in to comment.