-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
40 lines (33 loc) · 798 Bytes
/
Copy pathMakefile
File metadata and controls
40 lines (33 loc) · 798 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
33
34
35
36
37
38
39
40
.PHONY: install install-dev dev clean test build lint
# 安装全部依赖
install:
pip install -e ".[all]"
# 安装开发依赖
install-dev:
pip install -e ".[dev]"
# 启动开发服务器
dev:
uvicorn medilens.app:app --host 0.0.0.0 --port 8000 --reload
# 清除缓存文件
clean:
rm -rf __pycache__/
rm -rf .pytest_cache/
rm -rf *.egg-info/
rm -rf dist/
rm -rf build/
rm -rf .coverage
rm -rf htmlcov/
rm -rf outputs/
find . -type d -name "__pycache__" -exec rm -rf {} + 2>/dev/null || true
find . -type f -name "*.pyc" -delete
find . -type f -name "*.pyo" -delete
# 运行测试
test:
python -m pytest tests/ -v --cov=medilens
# 构建分发包
build:
python -m build
# 代码检查
lint:
python -m ruff check medilens/
python -m mypy medilens/ --ignore-missing-imports