forked from vllm-project/vllm
-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathMakefile
More file actions
95 lines (77 loc) · 2.89 KB
/
Copy pathMakefile
File metadata and controls
95 lines (77 loc) · 2.89 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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
# vLLM MUSA Platform Plugin - Makefile
# =====================================
.PHONY: help install dev-install pre-commit test test-cov build publish publish-test clean all
# Default target
help:
@echo "vLLM MUSA Platform Plugin - Available targets:"
@echo ""
@echo " Development:"
@echo " make dev-install - Install package in development mode"
@echo " make install - Install package"
@echo ""
@echo " Code Quality:"
@echo " make pre-commit - Run pre-commit hooks on all files"
@echo ""
@echo " Testing:"
@echo " make test - Run all tests"
@echo " make test-cov - Run tests with coverage report"
@echo ""
@echo " Build & Publish:"
@echo " make build - Build wheel and sdist"
@echo " make publish - Build and publish to PyPI"
@echo " make publish-test - Build and publish to TestPyPI"
@echo ""
@echo " Cleanup:"
@echo " make clean - Remove build artifacts"
@echo ""
@echo " Combined:"
@echo " make all - pre-commit, test, build"
# =============================================================================
# Development
# =============================================================================
dev-install:
pip install -e ".[dev]" --no-build-isolation -v
install:
pip install . --no-build-isolation -v
# =============================================================================
# Code Quality (via pre-commit)
# =============================================================================
pre-commit:
pre-commit run --all-files
# =============================================================================
# Testing
# =============================================================================
test:
pytest tests/ -v
test-cov:
pytest tests/ -v --cov=vllm_musa --cov-report=term-missing --cov-report=html
# =============================================================================
# Build & Publish
# =============================================================================
# Build wheel and source distribution
build: clean
python -m build
# Publish to PyPI
publish: build
python -m twine upload --repository pypi dist/*
# Publish to TestPyPI (for testing)
publish-test: build
python -m twine upload --repository testpypi dist/*
# =============================================================================
# Cleanup
# =============================================================================
clean:
rm -rf build/
rm -rf dist/
rm -rf *.egg-info/
rm -rf vllm_musa.egg-info/
rm -rf .pytest_cache/
rm -rf .coverage
rm -rf htmlcov/
rm -rf .ruff_cache/
find . -type d -name "__pycache__" -exec rm -rf {} + 2>/dev/null || true
find . -type f -name "*.pyc" -delete 2>/dev/null || true
# =============================================================================
# Combined Targets
# =============================================================================
all: pre-commit test build