Spaces:
Running
Running
| # DevOps Toolkit - Backend Makefile | |
| .PHONY: help install install-dev test test-cov lint type-check clean run format check all | |
| help: ## Show this help message | |
| install: ## Install production dependencies | |
| pip install -e . | |
| install-dev: ## Install development dependencies | |
| pip install -e ".[dev]" | |
| test: ## Run tests | |
| python -m pytest | |
| test-cov: ## Run tests with coverage | |
| python -m pytest --cov --cov-report=term-missing --cov-report=html | |
| lint: ## Run linting | |
| flake8 app/ tests/ | |
| type-check: ## Run type checking | |
| mypy app/ | |
| format: ## Format code with black and isort | |
| black app/ tests/ | |
| isort app/ tests/ | |
| check: ## Run all checks (lint, type-check, test) | |
| $(MAKE) lint | |
| $(MAKE) type-check | |
| $(MAKE) test | |
| clean: ## Clean up generated files | |
| find . -type f -name "*.pyc" -delete | |
| find . -type d -name "__pycache__" -delete | |
| find . -type d -name "*.egg-info" -exec rm -rf {} + | |
| rm -rf .coverage htmlcov/ .pytest_cache/ .mypy_cache/ | |
| run: ## Run the application | |
| python run.py | |
| run-dev: ## Run the application in development mode with auto-reload | |
| uvicorn app.main:app --reload --host 0.0.0.0 --port 8000 | |
| all: install-dev check ## Install dev dependencies and run all checks |