name: "Build and Publish" on: push: branches: - main env: PR_TITLE: "Create Release" COMMIT_MSG: "chore: create new release" concurrency: ${{ github.workflow }}-${{ github.ref }} jobs: publish: runs-on: ubuntu-latest strategy: matrix: node-version: [20.x] steps: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} - name: Install dependencies run: npm ci - name: Build package run: | npm run build npm run build-all - name: Create artifact uses: actions/upload-artifact@v4 with: name: dist path: dist/ retention-days: 2 - name: Create release uses: changesets/action@v1 id: changesets with: publish: npm run publish-package commit: ${{ env.COMMIT_MSG }} title: ${{ env.PR_TITLE }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }}