Skip to content

Commit 2a14a6a

Browse files
committed
Switched to elmahio/github-check-vulnerable-nuget-packages-action@v1
1 parent 832e14a commit 2a14a6a

File tree

1 file changed

+4
-13
lines changed

1 file changed

+4
-13
lines changed

.github/workflows/build.yml

+4-13
Original file line numberDiff line numberDiff line change
@@ -22,19 +22,10 @@ jobs:
2222
8.0.x
2323
- name: Install dependencies
2424
run: dotnet restore
25-
- name: Check for vulnerable packages
26-
run: |
27-
set -e # This will cause the script to exit on the first error
28-
OUTPUT=$(dotnet list src/Elmah.Io.Functions/Elmah.Io.Functions.csproj package --vulnerable)
29-
echo "$OUTPUT"
30-
if echo "$OUTPUT" | grep -q 'no vulnerable packages'; then
31-
echo "No vulnerable packages found"
32-
else
33-
if echo "$OUTPUT" | grep -q 'vulnerable'; then
34-
echo "Vulnerable packages found"
35-
exit 1
36-
fi
37-
fi
25+
- name: Check vulnerable NuGet packages
26+
uses: elmahio/github-check-vulnerable-nuget-packages-action@v1
27+
with:
28+
project: 'src/Elmah.Io.Functions/Elmah.Io.Functions.csproj'
3829
- name: Build
3930
run: dotnet build --configuration Release --no-restore
4031
- name: Test

0 commit comments

Comments
 (0)