Skip to Content
GitHub Actions

GitHub Actions

.github/workflows/release.yml
name: Release permissions: contents: write id-token: write on: workflow_dispatch: jobs: release: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: fetch-depth: 0 - name: Git config run: | git config user.name "github-actions[bot]" git config user.email "41898282+github-actions[bot]@users.noreply.github.com" - name: Set node uses: actions/setup-node@v4 with: node-version: lts/* registry-url: "https://registry.npmjs.org" - name: Install pnpm uses: pnpm/action-setup@v3 with: run_install: | - args: [--frozen-lockfile] - name: Release run: npx release-it --verbose env: GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} # Add following line if you are publishing to npm NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} NPM_CONFIG_PROVENANCE: true # Add more env variables if needed

Other

You can guard with should-semantic-release.

Last updated on