Merge pull request #176 from vue-pivottable/develop #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Release | |
| on: | |
| push: | |
| branches: | |
| - main | |
| concurrency: ${{ github.workflow }}-${{ github.ref }} | |
| jobs: | |
| release: | |
| name: Release | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| issues: write | |
| pull-requests: write | |
| id-token: write | |
| steps: | |
| - name: Generate GitHub App Token | |
| id: generate-token | |
| uses: tibdex/github-app-token@v1 | |
| with: | |
| app_id: ${{ secrets.APP_ID }} | |
| private_key: ${{ secrets.APP_PRIVATE_KEY }} | |
| installation_id: ${{ secrets.APP_INSTALLATION_ID }} | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| token: ${{ steps.generate-token.outputs.token }} | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '22.10.0' | |
| registry-url: 'https://registry.npmjs.org/' | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v2 | |
| with: | |
| version: latest | |
| - name: Install dependencies | |
| run: pnpm install | |
| - name: Create Release Pull Request or Publish | |
| id: changesets | |
| uses: changesets/action@v1 | |
| with: | |
| # This will create a PR with version bumps and changelog updates | |
| # When the PR is merged, it will publish to npm | |
| publish: pnpm release:packages | |
| version: pnpm changeset version | |
| commit: "chore: release packages" | |
| title: "chore: release packages" | |
| createGithubReleases: true | |
| env: | |
| GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }} | |
| NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
| NPM_TOKEN_SUMIN: ${{ secrets.NPM_TOKEN_SUMIN }} | |
| # Alternative: Use semantic-release with GitHub App token | |
| # - name: Release | |
| # env: | |
| # GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }} | |
| # NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
| # run: | | |
| # pnpm dlx semantic-release |