mirror of
https://github.com/github/codeql-action.git
synced 2026-04-02 01:32:17 +00:00
Add script to check whether npm i needs to be run
and add it to the `build` command
This commit is contained in:
7
scripts/check-node-modules.sh
Executable file
7
scripts/check-node-modules.sh
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
# Check if npm install is likely needed before proceeding
|
||||
if [ ! -d node_modules ] || [ package-lock.json -nt node_modules/.package-lock.json ]; then
|
||||
npm install
|
||||
fi
|
||||
Reference in New Issue
Block a user