Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion .github/workflows/auto-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ jobs:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
with:
fetch-depth: 0
persist-credentials: false # tag push below supplies the token explicitly

- name: Read version from package.json
id: version
Expand Down Expand Up @@ -125,13 +126,16 @@ jobs:
- name: Create annotated tag
if: steps.gate.outputs.skip != 'true' && steps.bumped.outputs.skip != 'true'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAG: ${{ steps.version.outputs.tag }}
run: |
set -euo pipefail
git config user.name 'askalf'
git config user.email 'support@askalf.org'
git tag -a "$TAG" -m "Release $TAG"
git push origin "$TAG"
# Push with an explicit token so it never lands in .git/config during the
# install+test step above (checkout runs persist-credentials: false).
git push "https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git" "$TAG"

- name: Create GitHub release
if: steps.gate.outputs.skip != 'true' && steps.bumped.outputs.skip != 'true'
Expand Down
Loading