Tldraw/.github/workflows/checks.yml

60 wiersze
1.3 KiB
YAML
Czysty Zwykły widok Historia

2023-04-21 16:06:21 +00:00
name: Checks
on:
pull_request:
merge_group:
push:
branches: [main, lite]
env:
CI: 1
PRINT_GITHUB_ANNOTATIONS: 1
jobs:
build:
name: 'Build and run checks'
timeout-minutes: 15
2023-04-21 16:18:25 +00:00
runs-on: ubuntu-latest-16-cores-open # TODO: this should probably run on multiple OSes
2023-04-21 16:06:21 +00:00
steps:
- name: Check out code
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: 18
cache: 'yarn'
2023-04-25 10:17:06 +00:00
cache-dependency-path: 'public-yarn.lock'
2023-04-21 16:06:21 +00:00
- name: Enable corepack
run: corepack enable
- name: Install dependencies
run: yarn
- name: Typecheck
2023-05-02 12:25:26 +00:00
run: yarn build-types
2023-04-21 16:06:21 +00:00
- name: Check scripts
run: yarn check-scripts
- name: Lint
run: yarn lint
- name: Check API declarations and docs work as intended
2023-05-02 12:25:26 +00:00
run: yarn api-check
2023-04-21 16:06:21 +00:00
- name: Pack public packages
2023-05-02 12:25:26 +00:00
run: "yarn lazy pack-tarball | sed -E 's/^.*? ::/::/'"
2023-04-21 16:06:21 +00:00
- name: Build all projects
# the sed pipe makes sure that github annotations come through without
# turbo's prefix
2023-05-02 12:25:26 +00:00
run: "yarn build | sed -E 's/^.*? ::/::/'"
2023-04-21 16:06:21 +00:00
- name: Test
run: yarn test