File tree Expand file tree Collapse file tree 1 file changed +50
-0
lines changed
Expand file tree Collapse file tree 1 file changed +50
-0
lines changed Original file line number Diff line number Diff line change 1+ name : .NET
2+
3+ on :
4+ push :
5+ branches : [ "master" ]
6+ pull_request :
7+ branches : [ "master" ]
8+
9+ jobs :
10+ build :
11+ runs-on : ubuntu-latest
12+
13+ permissions :
14+ actions : read
15+ contents : read
16+
17+ steps :
18+ - uses : actions/checkout@v4
19+
20+ - name : Setup .NET
21+ uses : actions/setup-dotnet@v4
22+ with :
23+ dotnet-version : 8.0.x
24+
25+ - name : Restore dependencies
26+ run : dotnet restore
27+
28+ - name : Build
29+ run : dotnet build --no-restore -c Debug
30+
31+ - name : Upload a Build Artifact
32+ uses : actions/upload-artifact@v4
33+ with :
34+ name : iis_Stupid_Menu-Beta
35+ path : bin/Debug/netstandard2.1/ii's Stupid Menu.dll
36+
37+ - name : Get Artifact URL
38+ id : artifact_url
39+ run : |
40+ ARTIFACT_RESPONSE=$(curl -s \
41+ -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
42+ -H "Accept: application/vnd.github+json" \
43+ "https://api.github.com/repos/${{ github.repository }}/actions/runs/${{ github.run_id }}/artifacts")
44+
45+ ARTIFACT_ID=$(echo "$ARTIFACT_RESPONSE" | jq -r '.artifacts[0].id')
46+ echo "artifact_id=$ARTIFACT_ID" >> $GITHUB_OUTPUT
47+ echo "artifact_url=https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}/artifacts/$ARTIFACT_ID" >> $GITHUB_OUTPUT
48+
49+ env :
50+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments