From 294303eb1e820d3f6f1c5a877f6237a3f40a0560 Mon Sep 17 00:00:00 2001 From: Max Ghenis Date: Tue, 20 Oct 2026 15:58:55 -0400 Subject: [PATCH] Run app Stylelint in CI; cover all apps in make typecheck/test CI's Lint and format job ran app's ESLint but never its Stylelint, which `bun run lint` (and so `make lint`) runs locally. Add a Stylelint step after ESLint (app) in both pr.yaml and push.yaml, keeping the two jobs identical. `make typecheck` and `make test` ran only in app/, while CI type-checks app, website and calculator-app and tests app and website. Make the targets match CI, say what they cover in `make help`, and list them in the before-committing steps. Co-Authored-By: Claude Opus 5.5 --- .github/workflows/pr.yaml | 4 ++++ .github/workflows/push.yaml | 4 ++++ Makefile | 9 ++++++--- docs/engineering/skills/repository-guidance.md | 3 ++- 4 files changed, 16 insertions(+), 4 deletions(-) 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.