name: PR on: [pull_request] jobs: pr: strategy: # Each step reports on its own; one red step must not cancel the others. fail-fast: false matrix: step: ['lint', 'test', 'build'] runs-on: ubuntu-latest env: YARN_ENABLE_SCRIPTS: false steps: - uses: actions/checkout@v4 - uses: actions/setup-node@v4 with: node-version: 'lts/*' - name: ${{ matrix.step }} run: | corepack enable yarn install --immutable yarn ${{ matrix.step }} # `yarn lint` runs eslint --fix and `yarn build` rewrites packageInfo.ts, # so both pass on a tree they changed. The committed tree must already be # what they produce. - name: tree unchanged run: git diff --exit-code --stat # The package.json each build/ directory holds is what npm receives: entry # points must exist, no ./build/ or ./cjs/cjs/ paths, no workspace: ranges. - name: check built manifests if: matrix.step == 'build' run: python3 scripts/check-built-manifests.py .