diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2b802af..ad1ea5e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -25,7 +25,9 @@ jobs: name: Release new version runs-on: ubuntu-latest outputs: - new_tag: ${{ steps.bump_verson.outputs.tag }} + new_tag: ${{ steps.bump_version.outputs.NEW_TAG }} + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} steps: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 @@ -34,12 +36,17 @@ jobs: registry-url: 'https://registry.npmjs.org' - run: npm ci - run: npm run build - - id: bump_verson - run: npm version ${{ inputs.version }} >> "$GITHUB_OUTPUT" + - run: | + git config user.name "github-actions[bot]" + git config user.email "41898282+github-actions[bot]@users.noreply.github" + - id: bump_version + run: echo "NEW_TAG=$(npm version ${{ inputs.version }})" >> $GITHUB_OUTPUT - run: git push --follow-tags github_release: name: Create a release runs-on: ubuntu-latest needs: release + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} steps: - run: gh release create ${{ needs.release.outputs.new_tag }} --draft --verify-tag