Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 10 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
.PHONY: help setup check test lint typecheck

PYTHON := $(shell test -x .venv/bin/python && printf '%s' .venv/bin/python || command -v python3)

help:
@printf '%s\n' \
'make setup Install the package and deterministic check dependencies' \
Expand All @@ -9,20 +11,21 @@ help:
'make typecheck Report the known mypy migration gap'

setup:
python3 -m pip install -e ".[test]"
@test -x .venv/bin/python || python3 -m venv .venv
.venv/bin/python -m pip install -e ".[test]"

check:
@python3 -c 'import pathlib,tomllib; r=pathlib.Path("."); d=tomllib.loads((r/"repo.toml").read_text()); assert d["schema_version"] == 1 and d["shape"] == "library"; [(_ for _ in ()).throw(AssertionError(f"missing {p}")) for p in ("README.md","repo.toml","Makefile","AGENTS.md","CLAUDE.md","docs/ARCHITECTURE.md") if not (r/p).exists()]'
python3 scripts/check_repo_hygiene.py
python3 -m ruff check src tests scripts
python3 -m pytest -q
@$(PYTHON) -c 'import pathlib,tomllib; r=pathlib.Path("."); d=tomllib.loads((r/"repo.toml").read_text()); assert d["schema_version"] == 1 and d["shape"] == "library"; [(_ for _ in ()).throw(AssertionError(f"missing {p}")) for p in ("README.md","repo.toml","Makefile","AGENTS.md","CLAUDE.md","docs/ARCHITECTURE.md") if not (r/p).exists()]'
$(PYTHON) scripts/check_repo_hygiene.py
$(PYTHON) -m ruff check src tests scripts
$(PYTHON) -m pytest -q
git diff --check

test:
python3 -m pytest -q
$(PYTHON) -m pytest -q

lint:
python3 -m ruff check src tests scripts
$(PYTHON) -m ruff check src tests scripts

typecheck:
@printf '%s\n' 'mypy is not yet a gate: 31 pre-existing typing findings are tracked in docs/ARCHITECTURE.md.'
Expand Down