-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
68 lines (48 loc) · 2.18 KB
/
Copy pathMakefile
File metadata and controls
68 lines (48 loc) · 2.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
.PHONY: format lint type-check pytest doc-coverage coverage coverage-html check \
ui-dev ui-build ui-test ui-lint ui-format ui-preview ui-analyze ui-check \
all-checks
# ── Python ────────────────────────────────────────────────────────────────────
format:
uv run ruff format .
lint:
uv run ruff check . --fix
type-check:
uv run mypy src
pytest:
uv run pytest
doc-coverage:
uv run interrogate src
# Line coverage. `--cov=scripts` is not optional and not cosmetic: sonar.sources
# is `src,scripts`, so SonarCloud counts every executable line under scripts/ as
# a line to cover whether or not the report mentions it. Omitting the directory
# does not exclude it — it reports all of it as uncovered, which once put
# new-code coverage at 37.8% on a PR whose script was covered at 99% locally.
# Keep this scope identical to the Pytest step in .github/workflows/ci.yml, or
# the number you read here is not the number the gate reads.
coverage:
uv run pytest --cov=cgis --cov=scripts --cov-report=term-missing
# Same scope, browsable. Writes htmlcov/ (git-ignored); open htmlcov/index.html.
coverage-html:
uv run pytest --cov=cgis --cov=scripts --cov-report=html
# Full Python verification (run before every commit/PR)
check: format lint type-check pytest doc-coverage
# ── UI (ui/) ──────────────────────────────────────────────────────────────────
ui-dev:
cd ui && bun dev
ui-build:
cd ui && bun run build
ui-test:
cd ui && bun run test:run
ui-lint:
cd ui && bun lint
ui-format:
cd ui && bun run format
ui-preview:
cd ui && bun run preview
ui-analyze:
cd ui && bun run analyze
# Full UI verification
ui-check: ui-lint ui-build ui-test
# ── Combined ──────────────────────────────────────────────────────────────────
# Run all checks (Python + UI)
all-checks: check ui-check