Skip to content

Commit b3d8c08

Browse files
Try attestation again (#324)
* Try attestation again * more updates * more updates
1 parent 80c9201 commit b3d8c08

3 files changed

Lines changed: 33 additions & 7 deletions

File tree

.github/workflows/publish.yaml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,14 @@
11
# Publish new releases to Bazel Central Registry.
22
name: Publish to BCR
33
on:
4+
workflow_call:
5+
inputs:
6+
tag_name:
7+
required: true
8+
type: string
9+
secrets:
10+
BCR_PUBLISH_TOKEN:
11+
required: true
412
workflow_dispatch:
513
inputs:
614
tag_name:
@@ -9,12 +17,12 @@ on:
917
type: string
1018
jobs:
1119
publish:
12-
uses: bazel-contrib/publish-to-bcr/.github/workflows/publish.yaml@v1.1.0
20+
uses: bazel-contrib/publish-to-bcr/.github/workflows/publish.yaml@v1.2.0
1321
with:
1422
tag_name: ${{ inputs.tag_name }}
1523
# GitHub repository which is a fork of the upstream where the Pull Request will be opened.
1624
registry_fork: maxwellE/bazel-central-registry
17-
attest: false
25+
attest: true
1826
author_name: Maxwell Elliott
1927
author_email: maxwell@elliott.now
2028
committer_name: Maxwell Elliott
@@ -25,4 +33,4 @@ jobs:
2533
attestations: write
2634
secrets:
2735
# Necessary to push to the BCR fork, and to open a pull request against a registry
28-
publish_token: ${{ secrets.BCR_PUBLISH_TOKEN }}
36+
publish_token: ${{ secrets.BCR_PUBLISH_TOKEN }}

.github/workflows/release.yaml

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,27 @@ jobs:
2121
with:
2222
release_files: archives/release.tar.gz
2323
prerelease: false
24+
draft: true
2425
tag_name: ${{ inputs.tag_name || github.ref_name }}
2526
permissions:
26-
id-token: write # Needed to attest provenance
27-
attestations: write # Needed to attest provenance
28-
contents: write # Needed to upload release files
27+
id-token: write # Needed to attest provenance
28+
attestations: write # Needed to attest provenance
29+
contents: write # Needed to upload release files
2930
secrets: {}
31+
publish:
32+
needs: release
33+
uses: ./.github/workflows/publish.yaml
34+
with:
35+
tag_name: ${{ inputs.tag_name || github.ref_name }}
36+
secrets:
37+
BCR_PUBLISH_TOKEN: ${{ secrets.BCR_PUBLISH_TOKEN }}
38+
finalize:
39+
needs: publish
40+
runs-on: ubuntu-latest
41+
permissions:
42+
contents: write
43+
steps:
44+
- run: gh release edit "$TAG" --draft=false --repo "$GITHUB_REPOSITORY"
45+
env:
46+
TAG: ${{ inputs.tag_name }}
47+
GH_TOKEN: ${{ github.token }}

MODULE.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module(
22
name = "bazel-diff",
3-
version = "18.0.0",
3+
version = "18.0.1",
44
compatibility_level = 0,
55
)
66

0 commit comments

Comments
 (0)