Skip to content

Commit a7df713

Browse files
committed
provide gh token on workflow_call
1 parent 5783d4f commit a7df713

3 files changed

Lines changed: 7 additions & 1 deletion

File tree

.github/workflows/build-rc-auto.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ jobs:
8686
if: needs.validate-and-check-label.outputs.has-label == 'true'
8787
with:
8888
base-branch: ${{ github.ref_name }}
89+
token: ${{ secrets.PR_TOKEN }}
8990
permissions:
9091
id-token: write
9192
contents: write

.github/workflows/build-rc-create.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ jobs:
1818
uses: ./.github/workflows/update-latest-build-version.yml
1919
with:
2020
base-branch: release/${{ inputs.semver }}
21+
token: ${{ secrets.PR_TOKEN }}
2122
permissions:
2223
id-token: write
2324
contents: write

.github/workflows/update-latest-build-version.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ on:
2020
description: 'The base branch, tag, or SHA for git operations and the pull request.'
2121
required: true
2222
type: string
23+
token:
24+
description: 'GitHub token for checkout and push operations.'
25+
required: true
26+
type: string
2327
outputs:
2428
build-version:
2529
description: 'Generated build version number'
@@ -43,7 +47,7 @@ jobs:
4347
with:
4448
fetch-depth: 0
4549
ref: ${{ inputs.base-branch }}
46-
token: ${{ secrets.PR_TOKEN }}
50+
token: ${{ inputs.token || secrets.PR_TOKEN }}
4751
- name: Bump build version
4852
id: bump-build-version
4953
shell: bash

0 commit comments

Comments
 (0)