diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 442fdf4..e17292d 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -27,9 +27,13 @@ jobs: with: node-version: 20 registry-url: https://registry.npmjs.org/ - - run: npm version minor -m "[ci skip] v%s" - env: - NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}} + - run: git config user.email "$GITHUB_ACTOR@users.noreply.github.com" + - run: git config user.name "$GITHUB_ACTOR" + - run: npm version minor -m "v%s" + - run: VERSION=$(node -p "require('./package.json').version") + - run: git tag ${VERSION} + - run: git push "https://$GITHUB_ACTOR:${{ secrets.ACCESS_TOKEN }}@github.com/$GITHUB_REPOSITORY.git" --follow-tags + - run: git push "https://$GITHUB_ACTOR:${{ secrets.ACCESS_TOKEN }}@github.com/$GITHUB_REPOSITORY.git" --tags - run: npm ci - run: npm publish env: