1313 tags :
1414 - ' *'
1515
16+ permissions :
17+ id-token : write
18+ contents : write
19+ attestations : write
20+
1621jobs :
1722 crate_metadata :
1823 name : Extract crate metadata
@@ -111,9 +116,7 @@ jobs:
111116 uses : dtolnay/rust-toolchain@stable
112117 with :
113118 targets : ${{ matrix.job.target }}
114- # On windows, for now build with 1.77.2, so that it works on windows 7.
115- # When we update the MSRV again, we'll need to revisit this, and probably drop support for Win7
116- toolchain : " ${{ contains(matrix.job.target, 'windows-') && '1.77.2' || 'stable' }}"
119+ toolchain : " stable"
117120
118121 - name : Install cross
119122 if : matrix.job.use-cross
@@ -223,12 +226,14 @@ jobs:
223226 BIN_PATH : ${{ steps.bin.outputs.BIN_PATH }}
224227
225228 - name : " Artifact upload: tarball"
229+ id : upload-tarball
226230 uses : actions/upload-artifact@master
227231 with :
228232 name : ${{ steps.package.outputs.PKG_NAME }}
229233 path : ${{ steps.package.outputs.PKG_PATH }}
230234
231235 - name : " Artifact upload: Debian package"
236+ id : upload-deb
232237 uses : actions/upload-artifact@master
233238 if : steps.debian-package.outputs.DPKG_NAME
234239 with :
@@ -242,6 +247,20 @@ jobs:
242247 unset IS_RELEASE ; if [[ $GITHUB_REF =~ ^refs/tags/v[0-9].* ]]; then IS_RELEASE='true' ; fi
243248 echo "IS_RELEASE=${IS_RELEASE}" >> $GITHUB_OUTPUT
244249
250+ - name : " Attest artifact: tarball"
251+ uses : actions/attest-build-provenance@v3
252+ if : steps.is-release.outputs.IS_RELEASE
253+ with :
254+ subject-name : ${{ steps.package.outputs.PKG_NAME }}
255+ subject-digest : sha256::${{ steps.upload-tarball.artifact-digest }}
256+
257+ - name : " Attest artifact: Debian package"
258+ uses : actions/attest-build-provenance@v3
259+ if : ' steps.is-release.outputs.IS_RELEASE && steps.debian-package.outputs.DPKG_NAME'
260+ with :
261+ subject-name : ${{ steps.debian-package.outputs.DPKG_NAME }}
262+ subject-digest : sha256::${{ steps.upload-deb.outputs.artifact-digest }}
263+
245264 - name : Publish archives and packages
246265 uses : softprops/action-gh-release@v2
247266 if : steps.is-release.outputs.IS_RELEASE
0 commit comments