.PHONY: install build publish publish-test test lint format podman clean run

install:
	uv sync --extra dev --group dev

build: format
	rm -rf dist
	uv build

publish: build
	uv publish

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

test:
	uv run pytest tests/

lint:
	uv run pylint taky

format:
	uv run black taky tests

podman: build
	podman build -t taky-ng .

coverage:
	uv run pytest --cov=taky --cov-report=term-missing

run: 
	podman run -it -p 8087:8087  -p 8443:8443 taky-ng 

version:
	uv run python -m setuptools_scm

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