Skip to content

Commit 7d2fe2f

Browse files
fix(ci): pass app token to Publish draft release step
The Publish draft release step used the workflow's default GITHUB_TOKEN, which does not return draft releases from listReleases — so the script failed with "Draft release for vX.Y.Z not found" and every release tag had to be undrafted manually. This same bug was fixed once before in 4db55ac ([ci] Add Github token to fetch draft releases) by adding github-token: GH_PAT to the listing step. It was lost during the refactor in 66a756b that combined the separate listing/flags/publish steps into a single Publish step, and not restored when f96b2da migrated remaining github-token usages from GH_PAT to the cozystack-ci App token. Add github-token: app-token.outputs.token to the merged step so it shares the same auth as the rest of the workflow. Assisted-By: Claude <[email protected]> Signed-off-by: Myasnikov Daniil <[email protected]>
1 parent 6e045e6 commit 7d2fe2f

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

‎.github/workflows/pull-requests-release.yaml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ jobs:
122122
- name: Publish draft release
123123
uses: actions/github-script@v7
124124
with:
125+
github-token: ${{ steps.app-token.outputs.token }}
125126
script: |
126127
const tag = '${{ steps.get_tag.outputs.tag }}';
127128
const m = tag.match(/^v(\d+\.\d+\.\d+)(-(?:alpha|beta|rc)\.\d+)?$/);

0 commit comments

Comments
 (0)