Skip to content

Commit 71c5fb7

Browse files
authored
Merge pull request LiuYunPlayer#21 from Do-sth-sharp/master
Add Artifacts Attestation
2 parents 55acb8c + 9715497 commit 71c5fb7

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

.github/workflows/build-artifacts.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,11 @@ jobs:
2121

2222
runs-on: windows-latest
2323

24+
permissions:
25+
id-token: write
26+
contents: read
27+
attestations: write
28+
2429
steps:
2530
- name: Checkout
2631
uses: actions/checkout@v4
@@ -51,6 +56,11 @@ jobs:
5156
shell: pwsh
5257
run: Move-Item -Path TuneLab\bin\Release\net8.0\${{ matrix.runtime }}\publish -Destination workspace
5358

59+
- name: Generate artifact attestation
60+
uses: actions/attest-build-provenance@v1
61+
with:
62+
subject-path: '"workspace/*.dll","workspace/*.exe"'
63+
5464
- name: Pack artifacts
5565
shell: pwsh
5666
run: Compress-Archive -Path workspace\* -DestinationPath ${env:ARCHIVE_NAME}'.zip'
@@ -79,6 +89,11 @@ jobs:
7989

8090
runs-on: macos-latest
8191

92+
permissions:
93+
id-token: write
94+
contents: read
95+
attestations: write
96+
8297
steps:
8398
- name: Checkout
8499
uses: actions/checkout@v4
@@ -108,6 +123,11 @@ jobs:
108123
- name: Move artifacts
109124
run: mv TuneLab/bin/Release/net8.0/${{ matrix.runtime }}/publish workspace
110125

126+
- name: Generate artifact attestation
127+
uses: actions/attest-build-provenance@v1
128+
with:
129+
subject-path: '"workspace/*.dll","workspace/ExtensionInstaller","workspace/TuneLab"'
130+
111131
- name: Pack artifacts
112132
run: |
113133
cd workspace
@@ -129,6 +149,11 @@ jobs:
129149

130150
runs-on: ubuntu-latest
131151

152+
permissions:
153+
id-token: write
154+
contents: read
155+
attestations: write
156+
132157
steps:
133158
- name: Checkout
134159
uses: actions/checkout@v4
@@ -158,6 +183,11 @@ jobs:
158183
- name: Move artifacts
159184
run: mv TuneLab/bin/Release/net8.0/${{ matrix.runtime }}/publish workspace
160185

186+
- name: Generate artifact attestation
187+
uses: actions/attest-build-provenance@v1
188+
with:
189+
subject-path: '"workspace/*.dll","workspace/ExtensionInstaller","workspace/TuneLab"'
190+
161191
- name: Pack artifacts
162192
run: |
163193
cd workspace

0 commit comments

Comments
 (0)