Skip to content

feat: enhance gesture handling with cancellation reporting #11

feat: enhance gesture handling with cancellation reporting

feat: enhance gesture handling with cancellation reporting #11

Workflow file for this run

name: CI / Build & Test
# Run when a change can affect what this workflow checks.
#
# `example/**` is in the list because the example app defines its own
# `typecheck` and `lint` scripts, and `pnpm run typecheck` runs Turborepo
# across every workspace package. If the example is not in the filter, a
# change that breaks the example typecheck passes review.
#
# The filter is deliberately wide. A wide filter costs an occasional run that
# proves nothing. A narrow filter costs a green build that is wrong.
on:
push:
branches:
- main
paths:
- "packages/**"
- "example/**"
- "scripts/**"
- "docs/**"
- "package.json"
- "pnpm-lock.yaml"
- "pnpm-workspace.yaml"
- "turbo.json"
- "tsconfig.base.json"
- "tsconfig.json"
- "jest.config.js"
- ".nvmrc"
- ".npmrc"
- ".github/workflows/ci-build.yml"
pull_request:
paths:
- "packages/**"
- "example/**"
- "scripts/**"
- "docs/**"
- "package.json"
- "pnpm-lock.yaml"
- "pnpm-workspace.yaml"
- "turbo.json"
- "tsconfig.base.json"
- "tsconfig.json"
- "jest.config.js"
- ".nvmrc"
- ".npmrc"
- ".github/workflows/ci-build.yml"
# The token only reads the repository.
permissions:
contents: read
concurrency:
group: ci-build-${{ github.ref }}
cancel-in-progress: true
jobs:
build-test:
name: Typecheck, test, build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5.1.0
- name: Setup pnpm
uses: pnpm/action-setup@0977fd99725f1db4007ccb2928dbb4e90d06cc86 # v6.0.10
# `cache: pnpm` is set on purpose. setup-node defaults
# `package-manager-cache` to true, reads the lockfile it finds, and then
# needs that package manager on PATH. pnpm is installed in the step
# above, so the default is correct here and naming it makes that clear.
- name: Setup Node.js
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 # v5.0.0
with:
node-version-file: .nvmrc
cache: "pnpm"
- name: Install dependencies
run: pnpm install --frozen-lockfile
# The Turborepo `typecheck` and `test` tasks both declare
# `dependsOn: ["^build"]`, so each one builds its dependencies first.
# The explicit build step below still has work to do: it builds the
# package itself, which proves the published `dist` compiles.
- name: Typecheck
run: pnpm run typecheck
- name: Test
run: pnpm run test
- name: Build package
run: pnpm run build
# A page edited without `pnpm run build:llms` leaves llms-full.txt and
# the package's shipped llms.txt describing the previous version. The
# check is `--check` on the generator itself rather than a second
# script, so the guard and the build cannot disagree about what correct
# means.
- name: llms.txt check
run: pnpm run check:llms
# Proves the docs site still compiles. `onBrokenLinks` is `throw`, so
# this also fails on a cross-link that points at a page that is not
# there — which is the failure a docs change is most likely to cause.
# It skips the example export on purpose: that runs a full Metro bundle
# and only the deploy needs it.
- name: Docs build
run: pnpm run docs:check
# Reads the built output and the tarball `files` would produce. Shared
# with both release workflows through `scripts/check-artifact.mjs`, so
# the guard that runs here is the guard that runs on the publishing
# path — a guard that runs on pull requests but not on release protects
# the branch and not the users.
- name: Artifact check
run: pnpm run check:artifact