Skip to content

Commit 0598362

Browse files
committed
sentinel: Run npm i on package updates
1 parent 1a0f79b commit 0598362

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/sentinel/hotpatch.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ export async function hotpatch(this: Sentinel, hotpatchType: HotpatchType, by: s
3939
switch (hotpatchType) {
4040
case 'code': {
4141
$`git pull`;
42+
// Run npm install if package-lock.json has been updated
43+
$`if git diff --name-only '@{1}' -- package-lock.json | grep -q .; then npm install; fi`;
4244
break;
4345
}
4446

0 commit comments

Comments
 (0)