Skip to content

Commit 0c7a1ec

Browse files
committed
Use merge_commit_sha, allowUpdates true, persist-credentials false
1 parent 27f00a4 commit 0c7a1ec

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

.github/workflows/release.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,7 @@ jobs:
8080
- name: Checkout repo
8181
uses: actions/checkout@v4
8282
with:
83-
token: ${{ secrets.SELENIUM_CI_TOKEN }}
84-
persist-credentials: true
83+
persist-credentials: false
8584
- name: Download release packages
8685
uses: actions/download-artifact@v4
8786
with:
@@ -95,18 +94,18 @@ jobs:
9594
gh release delete nightly --yes
9695
fi
9796
if git ls-remote --tags origin refs/tags/nightly | grep -q nightly; then
98-
git push origin --delete refs/tags/nightly
97+
gh api -X DELETE /repos/${{ github.repository }}/git/refs/tags/nightly
9998
fi
10099
- name: Create GitHub release
101100
uses: ncipollo/release-action@v1
102101
with:
103-
allowUpdates: ${{ github.run_attempt > 1 }}
102+
allowUpdates: true
104103
artifacts: "build/dist/*.*"
105104
bodyFile: "scripts/github-actions/release_header.md"
106105
generateReleaseNotes: true
107106
name: "Selenium ${{ needs.prepare.outputs.version }}"
108107
tag: "${{ needs.prepare.outputs.tag }}"
109-
commit: "${{ github.sha }}"
108+
commit: ${{ github.event.pull_request.merge_commit_sha || github.sha }}
110109

111110
verify:
112111
name: Verify Published Packages

0 commit comments

Comments
 (0)