Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 14 additions & 5 deletions .github/workflows/svalin-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,14 +87,23 @@ jobs:
run: |
echo "::group::Dependency Security Audit"

# Check for vulnerable patterns in dependencies
if [ -f "package.json" ]; then
echo "::error::Found package.json - should use Deno imports only"
# Policy: Bun > Deno > pnpm. Only Node.js and yarn are banned.
# package.json + bun.lock is the required JS manifest, and
# pnpm-lock.yaml is an allowed fallback lockfile.
if [ -f "package.json" ] && [ ! -f "bun.lock" ]; then
echo "::error::Found package.json without bun.lock - JS deps must be pinned via bun.lock"
exit 1
fi

if [ -f "package-lock.json" ] || [ -f "yarn.lock" ] || [ -f "pnpm-lock.yaml" ]; then
echo "::error::Found npm/yarn/pnpm lockfiles - not allowed per RSR policy"
# Node-only lockfiles (npm, yarn) are banned.
if [ -f "package-lock.json" ] || [ -f "npm-shrinkwrap.json" ] || [ -f "yarn.lock" ] || [ -f ".yarnrc.yml" ] || [ -f ".yarnrc" ]; then
echo "::error::Found npm/yarn artefacts - Node.js and yarn are banned per language policy"
exit 1
fi

# Node-only runtime pins are banned.
if [ -f ".nvmrc" ] || [ -f ".node-version" ]; then
echo "::error::Found Node.js version pin (.nvmrc/.node-version) - Node.js is banned; use Bun"
exit 1
fi

Expand Down
Loading