-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathMakefile
More file actions
39 lines (33 loc) · 1.13 KB
/
Makefile
File metadata and controls
39 lines (33 loc) · 1.13 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
.PHONY: install app check fix clean help
# Default target
help:
@echo "Available commands:"
@echo " make install - Install dependencies and pre-commit hooks"
@echo " make app - Run the Streamlit app"
@echo " make check - Run linting, pre-commit, and type checking"
@echo " make fix - Auto-fix lint issues and format code"
@echo " make clean - Remove cache and build artifacts"
install:
uv sync
uv run pre-commit install --hook-type pre-commit --install-hooks --overwrite
app:
uv run streamlit run 🚧_Streamlit_Issue_Explorer.py
check:
# Lint with ruff:
uv run ruff check
# Check formatting (run `make fix` if this fails):
uv run ruff format --check
# Type check with ty:
uv run ty check
# Type check with mypy:
uv run mypy
fix:
# Apply lint fixes with ruff but dont fail:
uv run ruff check --fix || true
# Format code with ruff:
uv run ruff format || true
# Run pre-commit hooks to apply fixes (ignore exit code):
uv run pre-commit run || true
clean:
rm -rf .venv __pycache__ .pytest_cache .mypy_cache .ruff_cache
find . -type d -name "__pycache__" -exec rm -rf {} + 2>/dev/null || true