Open History to see the last commit
1name: pr
2β
3on:
4 pull_request:
5β
6concurrency:
7 group: ${{ github.workflow }}-${{ github.event.number || github.ref }}
8 cancel-in-progress: true
9β
10env:
11 NX_CLOUD_ACCESS_TOKEN: ${{ secrets.NX_CLOUD_ACCESS_TOKEN }}
12β
13permissions:
14 contents: read
15β
16jobs:
17 test:
18 name: Test
19 runs-on: ubuntu-latest
20 steps:
21 - name: Checkout
22 uses: actions/checkout@v4
23 with:
24 fetch-depth: 0
25 - name: Start Nx Agents
26 run: npx nx-cloud start-ci-run --distribute-on=".nx/workflows/dynamic-changesets.yaml"
27 - name: Setup Tools
28 uses: tanstack/config/.github/setup@main
29 - name: Get base and head commits for `nx affected`
30 uses: nrwl/nx-set-shas@v4
31 with:
32 main-branch-name: main
33 - name: Run Checks
34 run: pnpm run test:pr --parallel=3
35 - name: Stop Nx Agents
36 if: ${{ always() }}
37 run: npx nx-cloud stop-all-agents
38 preview:
39 name: Preview
40 runs-on: ubuntu-latest
41 steps:
42 - name: Checkout
43 uses: actions/checkout@v4
44 with:
45 fetch-depth: 0
46 - name: Setup Tools
47 uses: tanstack/config/.github/setup@main
48 - name: Build Packages
49 run: pnpm run build:all
50 - name: Publish Previews
51 run: pnpx pkg-pr-new publish --pnpm --compact './packages/*' --no-template