# Lint, test and build on every push.
#
# This needs a Gitea Actions runner registered against the instance.  If there
# isn't one, delete this file - nothing else depends on it, and `npm test &&
# npm run build` locally covers the same ground.

name: CI

on:
  push:
    branches: [main]
  pull_request:
    branches: [main]

jobs:
  check:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - uses: actions/setup-node@v4
        with:
          node-version: "22"
          cache: "npm"

      - run: npm ci

      # Asserts the transforms still produce the rosters the Python scripts they
      # were ported from produced; see README.md.
      - run: npm test

      - run: npm run build
