2022-06-21 12:28:01 -07:00
|
|
|
# Run tests and linters
|
2022-06-20 12:54:46 -07:00
|
|
|
@default: test lint
|
|
|
|
|
|
2022-06-21 12:28:01 -07:00
|
|
|
# Run pytest with supplied options
|
2022-06-20 12:54:46 -07:00
|
|
|
@test *options:
|
2025-12-11 15:32:00 -08:00
|
|
|
uv run pytest {{options}}
|
2025-11-23 19:41:57 -08:00
|
|
|
|
|
|
|
|
@run *options:
|
2025-12-11 15:32:00 -08:00
|
|
|
uv run -- {{options}}
|
2022-06-20 12:54:46 -07:00
|
|
|
|
2026-07-05 15:38:05 -07:00
|
|
|
# Run linters: black, flake8, mypy, ty, cog
|
2022-06-20 12:54:46 -07:00
|
|
|
@lint:
|
2025-11-23 19:41:57 -08:00
|
|
|
just run black . --check
|
2025-12-11 15:32:00 -08:00
|
|
|
uv run flake8
|
|
|
|
|
uv run mypy sqlite_utils tests
|
2026-07-05 15:38:05 -07:00
|
|
|
uv run ty check sqlite_utils
|
2025-12-11 15:32:00 -08:00
|
|
|
uv run cog --check README.md docs/*.rst
|
|
|
|
|
uv run --group docs codespell docs/*.rst --ignore-words docs/codespell-ignore-words.txt
|
2022-06-21 12:24:23 -07:00
|
|
|
|
2022-06-21 12:28:01 -07:00
|
|
|
# Rebuild docs with cog
|
2022-06-21 12:24:23 -07:00
|
|
|
@cog:
|
2025-12-11 15:32:00 -08:00
|
|
|
uv run --group docs cog -r README.md docs/*.rst
|
2022-06-20 12:54:46 -07:00
|
|
|
|
2022-09-26 12:36:09 -07:00
|
|
|
# Serve live docs on localhost:8000
|
2022-09-26 12:09:00 -07:00
|
|
|
@docs: cog
|
2025-11-23 19:41:57 -08:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
cd docs
|
2025-12-11 15:32:00 -08:00
|
|
|
uv run --group docs make livehtml
|
2025-11-23 19:41:57 -08:00
|
|
|
|
2022-09-26 12:09:00 -07:00
|
|
|
|
2022-06-21 12:28:01 -07:00
|
|
|
# Apply Black
|
2022-06-20 12:54:46 -07:00
|
|
|
@black:
|
2025-12-11 15:32:00 -08:00
|
|
|
uv run black .
|