-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
32 lines (22 loc) · 836 Bytes
/
Makefile
File metadata and controls
32 lines (22 loc) · 836 Bytes
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
.PHONY: build check clean-build format format-check lint test typecheck verify-dist
PYTHON ?= python
UV_CACHE_DIR ?= .uv-cache
test:
UV_CACHE_DIR=$(UV_CACHE_DIR) uv run $(PYTHON) -m unittest discover -s tests
typecheck:
UV_CACHE_DIR=$(UV_CACHE_DIR) uv run mypy
lint:
UV_CACHE_DIR=$(UV_CACHE_DIR) uv run ruff check src tests
format:
UV_CACHE_DIR=$(UV_CACHE_DIR) uv run ruff format src tests
format-check:
UV_CACHE_DIR=$(UV_CACHE_DIR) uv run ruff format --check src tests
clean-build:
rm -rf build src/hermes_membase.egg-info
mkdir -p dist
find dist -maxdepth 1 -type f \( -name '*.whl' -o -name '*.tar.gz' \) -delete
build: clean-build
UV_CACHE_DIR=$(UV_CACHE_DIR) uv run $(PYTHON) -m build
verify-dist: build
UV_CACHE_DIR=$(UV_CACHE_DIR) uv run twine check dist/*
check: typecheck lint format-check test verify-dist