# Simple developer Makefile for can-you-assist
# Focus: easy dev-head install and common tasks

.PHONY: dev-install install test clean dist

# Install the package in editable mode from the current source
# This is the recommended way to work on the latest code
dev-install:
	pip install -e ".[dev]"

# Standard install (for comparison / released packages later)
install:
	pip install .

# Run the test suite
test:
	python3 -m pytest tests/ -q

# Clean build artifacts
clean:
	rm -rf build/ dist/ *.egg-info/ src/cya/_version.py
	find . -type d -name __pycache__ -exec rm -rf {} + 2>/dev/null || true

# Build distribution packages (sdist + wheel)
dist: clean
	python -m build

# Show current version (useful after setuptools_scm changes)
version:
	python3 -c "import cya; print(cya.__version__)"