name: CI on: push: paths-ignore: - 'docs/**' branches: - main pull_request: paths-ignore: - 'docs/**' branches: - main jobs: build: runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest] node: [16] steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} cache: 'yarn' - name: Install dependencies run: yarn --immutable - name: Build run: yarn build - name: Cache dist uses: actions/cache@v3 with: path: packages/*/dist key: ${{ matrix.os }}-node-v${{ matrix.node }}-${{ github.sha }} lint: runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest] node: [16] steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} cache: 'yarn' - name: Install dependencies run: yarn --immutable - name: Lint run: yarn lint typecheck: runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest] node: [16] steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} cache: 'yarn' - name: Install dependencies run: yarn --immutable - name: Stub run: yarn stub - name: Typecheck run: yarn typecheck test-fixtures: runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest, windows-latest] node: [16] steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} cache: 'yarn' - name: Install dependencies run: yarn --immutable - name: Stub run: yarn stub - name: Test (unit) run: yarn test:unit - name: Test (fixtures) run: yarn test:fixtures - name: Test (fixtures with dev) run: yarn test:fixtures:dev env: NODE_OPTIONS: --max-old-space-size=8192 test-fixtures-webpack: runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest, windows-latest] node: [16] steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} cache: 'yarn' - name: Install dependencies run: yarn --immutable - name: Stub run: yarn stub - name: Test (fixtures) run: yarn test:fixtures:webpack test-types: needs: - build runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest] node: [16] steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} cache: 'yarn' - name: Install dependencies run: yarn --immutable - name: Restore dist cache uses: actions/cache@v3 with: path: packages/*/dist key: ${{ matrix.os }}-node-v${{ matrix.node }}-${{ github.sha }} - name: Test (types) run: yarn test:types build-release: if: | github.event_name == 'push' && !contains(github.event.head_commit.message, '[skip-release]') && !contains(github.event.head_commit.message, 'chore') && !contains(github.event.head_commit.message, 'docs') needs: - lint - build - test-fixtures - test-fixtures-webpack - test-types runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest] node: [16] steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} cache: 'yarn' - name: Install dependencies run: yarn --immutable - name: Restore dist cache uses: actions/cache@v3 with: path: packages/*/dist key: ${{ matrix.os }}-node-v${{ matrix.node }}-${{ github.sha }} - name: Release Edge run: ./scripts/release-edge.sh env: NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}}