Skip to content

Commit 72703d0

Browse files
authored
Suddenly existing repos fail with missing permissions for token (#271)
1 parent b2c568f commit 72703d0

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

.github/workflows/main.yml

+2
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ jobs:
1515
bump-version:
1616
if: github.event_name == 'pull_request' && github.event.action == 'closed' && github.event.pull_request.merged == true
1717
runs-on: ubuntu-22.04
18+
permissions:
19+
contents: write
1820
steps:
1921
- uses: actions/checkout@v3
2022
with:

entrypoint.sh

+1
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,7 @@ fi
242242
git tag "$new"
243243

244244
# push new tag ref to github
245+
# this needs permissions in the workflow as contents: write
245246
dt=$(date '+%Y-%m-%dT%H:%M:%SZ')
246247
full_name=$GITHUB_REPOSITORY
247248
git_refs_url=$(jq .repository.git_refs_url "$GITHUB_EVENT_PATH" | tr -d '"' | sed 's/{\/sha}//g')

0 commit comments

Comments
 (0)