Compare commits
1 Commits
9fd503d45b
...
150bca647e
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
150bca647e |
@@ -393,12 +393,17 @@ runs:
|
||||
|
||||
# Verify npm installation
|
||||
if [ -f "$MODULE_PATH/package.json" ]; then
|
||||
NODE_DEP_COUNT=$(jq -r '((.dependencies // {}) | length) + ((.optionalDependencies // {}) | length)' "$MODULE_PATH/package.json" 2>/dev/null || echo "0")
|
||||
if [ "$NODE_DEP_COUNT" -gt 0 ]; then
|
||||
if [ -d "$MODULE_PATH/node_modules" ]; then
|
||||
echo " ✓ Node dependencies installed (node_modules/ exists)"
|
||||
else
|
||||
echo "::error::package.json exists but node_modules/ directory not found in $MODULE_NAME"
|
||||
echo "::error::package.json has production dependencies but node_modules/ directory not found in $MODULE_NAME"
|
||||
exit 1
|
||||
fi
|
||||
else
|
||||
echo " ✓ Node module has no production dependencies (node_modules/ not required)"
|
||||
fi
|
||||
fi
|
||||
|
||||
echo " ✓ $MODULE_NAME verified"
|
||||
|
||||
Reference in New Issue
Block a user