diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index cc2559060..f29d3cb57 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -35,6 +35,10 @@ jobs: working-directory: ./app run: bun run eslint + - name: Run Stylelint (app) + working-directory: ./app + run: bun run stylelint + - name: Check formatting with Prettier (website) working-directory: ./website run: bun run format:check diff --git a/.github/workflows/push.yaml b/.github/workflows/push.yaml index 7f0efc9f7..c774f704b 100644 --- a/.github/workflows/push.yaml +++ b/.github/workflows/push.yaml @@ -28,6 +28,10 @@ jobs: working-directory: ./app run: bun run eslint + - name: Run Stylelint (app) + working-directory: ./app + run: bun run stylelint + - name: Check formatting with Prettier (website) working-directory: ./website run: bun run format:check diff --git a/Makefile b/Makefile index 7cfd0a8fd..4218c0bb5 100644 --- a/Makefile +++ b/Makefile @@ -1,12 +1,12 @@ -.PHONY: help install dev build test lint format clean deploy +.PHONY: help install dev build typecheck test-all test lint format clean deploy help: @echo "Available commands:" @echo " make install - Install dependencies" @echo " make dev - Start Next.js website + calculator dev servers" @echo " make build - Build the website and calculator" - @echo " make typecheck - Run type checks" - @echo " make test - Run tests" + @echo " make typecheck - Run type checks (app, website, calculator)" + @echo " make test - Run tests (app, website)" @echo " make lint - Run linters" @echo " make format - Format code" @echo " make clean - Clean build artifacts" @@ -23,12 +23,15 @@ build: typecheck: cd app && bun run typecheck + cd website && bun run typecheck + cd calculator-app && bun run typecheck test-all: cd app && bun run test-all test: cd app && bun run test + cd website && bun run test lint: cd app && bun run lint diff --git a/docs/engineering/skills/repository-guidance.md b/docs/engineering/skills/repository-guidance.md index 5b4077899..57a31ce4a 100644 --- a/docs/engineering/skills/repository-guidance.md +++ b/docs/engineering/skills/repository-guidance.md @@ -125,4 +125,5 @@ No route embeds a GitHub Pages site as a whole page any more: the 2025 year in r 1. Run `make format` to format `app/`, `website/` and `calculator-app/` with Prettier. `app/` has its own Prettier config; `website/` and `calculator-app/` use Prettier's defaults. 2. Run `make lint` to run ESLint (and Stylelint in `app/`) in all three. -3. CI fails on ESLint warnings as well as errors (`--max-warnings 0`), and on files Prettier would reformat, so fix all of them. +3. Run `make typecheck` to type-check all three, and `make test` to run the `app/` and `website/` tests (`calculator-app/` has none). These match CI's type checking and tests jobs. +4. CI fails on ESLint warnings as well as errors (`--max-warnings 0`), and on files Prettier would reformat, so fix all of them.