build: Check package-lock.json in post-merge, too

This commit is contained in:
Colin Caine 2017-11-22 23:06:42 +00:00
parent 2611f4fe79
commit 80db6e7297

View file

@ -5,8 +5,10 @@
changed_files="$(git diff-tree -r --name-only --no-commit-id ORIG_HEAD HEAD)"
check_run() {
echo "$changed_files" | grep --quiet "$1" && eval "$2"
file_changed() {
echo "$changed_files" | grep --quiet "$1"
}
check_run package.json "npm install"
if file_changed package.json || file_changed package-lock.json; then
npm install
fi