.PHONY: help clean build test install publish-test publish

help:
	@echo "Available targets:"
	@echo "  clean        - Remove build artifacts and cache files"
	@echo "  build        - Build the package"
	@echo "  test         - Run tests"
	@echo "  install      - Install package in development mode"
	@echo "  publish-test - Publish to TestPyPI"
	@echo "  publish      - Publish to PyPI"

clean:
	rm -rf dist/
	rm -rf build/
	rm -rf *.egg-info/
	find . -type d -name __pycache__ -exec rm -rf {} +
	find . -type f -name "*.pyc" -delete

build: clean
	uv build

test:
	uv run pytest

install:
	uv pip install -e .

publish-test: build
	uv publish --publish-url https://test.pypi.org/legacy/

publish: build
	uv publish

# Quick development cycle
dev-install: clean build install
