Skip to content

Commit 297533f

Browse files
chore: enable immutable releases (#1822)
* chore: enable immutable releases * Potential fix for code scanning alert no. 2: Workflow does not contain permissions Note: Future AI-generated commits are _not_ welcome. Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --------- Co-authored-by: Alex Eagle <alex@aspect.dev> Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
1 parent 671df82 commit 297533f

2 files changed

Lines changed: 13 additions & 2 deletions

File tree

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

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ on:
2424

2525
jobs:
2626
publish-to-bcr:
27-
uses: bazel-contrib/publish-to-bcr/.github/workflows/publish.yaml@v1.0.0
27+
uses: bazel-contrib/publish-to-bcr/.github/workflows/publish.yaml@v1.2.0
2828
with:
2929
tag_name: ${{ inputs.tag_name }}
3030
# bazelbuild/bazel-central-registry fork used to open a pull request.
@@ -38,3 +38,13 @@ jobs:
3838
secrets:
3939
# Necessary to push to the BCR fork and open a pull request.
4040
publish_token: ${{ secrets.bcr_publish_token }}
41+
finalize:
42+
permissions:
43+
contents: write
44+
needs: publish-to-bcr
45+
runs-on: ubuntu-latest
46+
steps:
47+
- run: gh release edit "$TAG" --draft=false --repo "$GITHUB_REPOSITORY"
48+
env:
49+
TAG: ${{ inputs.tag_name }}
50+
GH_TOKEN: ${{ github.token }}

.github/workflows/release.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,11 @@ permissions:
2727

2828
jobs:
2929
release:
30-
uses: bazel-contrib/.github/.github/workflows/release_ruleset.yaml@v7.2.3
30+
uses: bazel-contrib/.github/.github/workflows/release_ruleset.yaml@v7.4.0
3131
with:
3232
bazel_test_command: "bazel test //src/... //test/... //third_party/..."
3333
prerelease: false
34+
draft: true
3435
release_files: rules_scala-*.tar.gz
3536
tag_name: ${{ inputs.tag_name || github.ref_name }}
3637

0 commit comments

Comments
 (0)