Skip to content

Commit c4afeaf

Browse files
committed
List globally installed packages after uninstall
1 parent 65e54ef commit c4afeaf

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.github/workflows/scripts/test_install

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,11 @@ npm_install_global() {
291291
echo "Encountered an error when performing post-install cleanup tasks." >> "${log_file}" 2>&1
292292
return 1
293293
fi
294+
npm list -g --depth=0 >> "${log_file}" 2>&1
295+
if [[ "$?" -ne 0 ]]; then
296+
echo "Encountered an error when attempting to list globally installed packages via npm." >> "${log_file}" 2>&1
297+
return 1
298+
fi
294299
echo 'Successfully removed global installation...' >> "${log_file}" 2>&1
295300
return 0
296301
}
@@ -324,6 +329,11 @@ npm_install_global_github() {
324329
echo "Encountered an error when performing post-install cleanup tasks." >> "${log_file}" 2>&1
325330
return 1
326331
fi
332+
npm list -g --depth=0 >> "${log_file}" 2>&1
333+
if [[ "$?" -ne 0 ]]; then
334+
echo "Encountered an error when attempting to list globally installed packages via npm." >> "${log_file}" 2>&1
335+
return 1
336+
fi
327337
echo 'Successfully removed global installation...' >> "${log_file}" 2>&1
328338
return 0
329339
}

0 commit comments

Comments
 (0)