Skip to content

File tree

2 files changed

+15
-8
lines changed

2 files changed

+15
-8
lines changed

.github/workflows/publish-to-bcr.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ on:
88
tag_name:
99
required: true
1010
type: string
11+
secrets:
12+
publish_token:
13+
required: true
14+
1115
# In case of problems, enable manual dispatch from the GitHub UI.
1216
workflow_dispatch:
1317
inputs:
@@ -28,4 +32,4 @@ jobs:
2832
id-token: write
2933
secrets:
3034
# Necessary to push to the BCR fork and open a pull request.
31-
publish_token: ${{ secrets.PUBLISH_TOKEN }}
35+
publish_token: ${{ secrets.publish_token }}

.github/workflows/release.yml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ on:
66
push:
77
tags:
88
- 'v*.*.*'
9+
910
# In case of problems, enable manual dispatch from the GitHub UI.
1011
workflow_dispatch:
1112
inputs:
@@ -16,24 +17,26 @@ on:
1617
# Based on the following, which uses the `release_ruleset` workflow to generate
1718
# provenance attestation files referenced by the `publish-to-bcr` workflow.
1819
# https://github.com/aspect-build/rules_lint/blob/v1.3.1/.github/workflows/release.yml
20+
21+
permissions:
22+
attestations: write # Needed to attest provenance
23+
contents: write # Needed to create release
24+
id-token: write # Needed to attest provenance
25+
1926
jobs:
2027
release:
21-
uses: bazel-contrib/.github/.github/workflows/[email protected]
28+
uses: bazel-contrib/.github/.github/workflows/[email protected].0
2229
with:
2330
bazel_test_command: "bazel test //src/... //test/... //third_party/..."
2431
prerelease: false
2532
release_files: rules_scala-*.tar.gz
2633
release_prep_command: .github/workflows/workspace_snippet.sh
2734
tag_name: ${{ github.ref_name }}
28-
permissions:
29-
attestations: write # Needed to attest provenance
30-
contents: write # Needed to create release
31-
id-token: write # Needed to attest provenance
3235

3336
publish-to-bcr:
3437
needs: release
3538
uses: ./.github/workflows/publish-to-bcr.yml
3639
with:
3740
tag_name: ${{ github.ref_name }}
38-
permissions:
39-
contents: write # allow appending new attestation files to the release
41+
secrets:
42+
publish_token: ${{ secrets.PUBLISH_TOKEN }}

0 commit comments

Comments
 (0)