0bd6410d9f
We had a few issues with lazy race conditions failing CI. This came from scripts configured to invoke lazy again, rather than through expressing dependencies between scripts. This diff reconfigures lazy to articulate these sorts of things as dependencies instead of through self-invocation. Instead of having lots of separate `build-package`, `build-docs`, etc commands, we now just have a build command with package overrides to express more specific options ### Change Type - [x] `internal` — Any other changes that don't affect the published package (will not publish a new version) ### Release Notes [internal only]
61 lines
1.3 KiB
YAML
61 lines
1.3 KiB
YAML
name: Checks
|
|
|
|
on:
|
|
pull_request:
|
|
merge_group:
|
|
push:
|
|
branches: [main, lite]
|
|
|
|
env:
|
|
CI: 1
|
|
PRINT_GITHUB_ANNOTATIONS: 1
|
|
|
|
defaults:
|
|
run:
|
|
shell: bash
|
|
|
|
jobs:
|
|
build:
|
|
name: 'Build and run checks'
|
|
timeout-minutes: 15
|
|
runs-on: ubuntu-latest-16-cores-open # TODO: this should probably run on multiple OSes
|
|
|
|
steps:
|
|
- name: Check out code
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Setup Node.js environment
|
|
uses: actions/setup-node@v3
|
|
with:
|
|
node-version: 18
|
|
cache: 'yarn'
|
|
cache-dependency-path: 'public-yarn.lock'
|
|
|
|
- name: Enable corepack
|
|
run: corepack enable
|
|
|
|
- name: Install dependencies
|
|
run: yarn
|
|
|
|
- name: Typecheck
|
|
run: yarn build-types
|
|
|
|
- name: Check scripts
|
|
run: yarn check-scripts
|
|
|
|
- name: Lint
|
|
run: yarn lint
|
|
|
|
- name: Check API declarations and docs work as intended
|
|
run: yarn api-check
|
|
|
|
- name: Build all projects
|
|
# the sed pipe makes sure that github annotations come through without
|
|
# turbo's prefix
|
|
run: "yarn build | sed -E 's/^.*? ::/::/'"
|
|
|
|
- name: Pack public packages
|
|
run: "yarn lazy pack-tarball | sed -E 's/^.*? ::/::/'"
|
|
|
|
- name: Test
|
|
run: yarn test
|