From b53ef3d288db128c302be026ff2840e2f6d58220 Mon Sep 17 00:00:00 2001 From: Sergio Moya <1083296+smoya@users.noreply.github.com> Date: Mon, 10 Oct 2022 13:59:33 +0200 Subject: [PATCH] ci: add check for package-lock.json version --- .github/workflows/if-nodejs-pr-testing.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/if-nodejs-pr-testing.yml b/.github/workflows/if-nodejs-pr-testing.yml index 1dcccd32..45c63b2b 100644 --- a/.github/workflows/if-nodejs-pr-testing.yml +++ b/.github/workflows/if-nodejs-pr-testing.yml @@ -33,6 +33,10 @@ jobs: id: packagejson run: test -e ./package.json && echo "::set-output name=exists::true" || echo "::set-output name=exists::false" shell: bash + - if: steps.packagejson.outputs.exists == 'true' + name: Check package-lock.json version is '2' + run: | + grep '"lockfileVersion": 2' package-lock.json - if: steps.packagejson.outputs.exists == 'true' name: Setup Node.js uses: actions/setup-node@v2