forked from morganstanley/ComposeUI
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (33 loc) · 1.12 KB
/
dependency-submission.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: Dependency Submission
on:
workflow_dispatch:
#push:
permissions:
id-token: write
contents: write
jobs:
dependency-submission:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
- name: Create csproj from props
run: Copy-Item .\Directory.Packages.props -Destination .\Directory.Packages.csproj
- name: amend csproj
run: |
$file = Get-Content .\Directory.Packages.csproj
$file | ForEach-Object {
if($_.ReadCount -eq 1){
$_ -replace '<Project>', '<Project Sdk="Microsoft.NET.Sdk">'
} else {
$_
}
} | Set-Content .\Directory.Packages.csproj
- name: add csproj to a build-time temp solution
run: |
dotnet new sln --name cve-detection
dotnet sln .\cve-detection.sln add .\Directory.Packages.csproj
- name: Component detection
uses: advanced-security/[email protected]
with:
detectorsFilter: "Npm,NuGet"
filePath: "."