Skip to content

Commit c9dffe8

Browse files
tkislanjamesbhobbs
andauthored
ci: Add package.lock drift check CI step (#140)
* ci: Add package.lock drift check CI step Signed-off-by: Tomas Kislan <tomas@kislan.sk> * test: Manually change package-lock.json to test CI drift check Signed-off-by: Tomas Kislan <tomas@kislan.sk> * ci: Add NODE_AUTH_TOKEN environment variable for dependency installation in CI workflow Signed-off-by: Tomas Kislan <tomas@kislan.sk> * fix: Revert package-lock.json manual change Signed-off-by: Tomas Kislan <tomas@kislan.sk> * refactor: Simplify package-lock.json git diff CI step Signed-off-by: Tomas Kislan <tomas@kislan.sk> * ci: Reduce timeout Co-authored-by: James Hobbs <15235276+jamesbhobbs@users.noreply.github.com> --------- Signed-off-by: Tomas Kislan <tomas@kislan.sk> Co-authored-by: James Hobbs <15235276+jamesbhobbs@users.noreply.github.com>
1 parent b8c52a6 commit c9dffe8

File tree

1 file changed

+25
-0
lines changed

1 file changed

+25
-0
lines changed

.github/workflows/ci.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,31 @@ jobs:
190190
- name: Run spell check
191191
run: npm run spell-check
192192

193+
package-lock-drift-check:
194+
name: Package Lock Drift Check
195+
runs-on: ubuntu-latest
196+
timeout-minutes: 5
197+
steps:
198+
- name: Checkout
199+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5
200+
201+
- name: Setup Node.js
202+
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6
203+
with:
204+
cache: 'npm'
205+
node-version-file: '.nvmrc'
206+
registry-url: 'https://npm.pkg.github.com'
207+
scope: '@deepnote'
208+
209+
- name: Install dependencies
210+
run: npm install
211+
env:
212+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
213+
214+
- name: Check package lock drift
215+
run: |
216+
git diff --exit-code HEAD
217+
193218
audit-prod:
194219
name: Audit - Production
195220
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)