Makefile 646 B

1234567891011121314151617181920212223242526272829303132
  1. .PHONY: run dev test lint clean install
  2. install:
  3. pip install -r requirements.txt
  4. run:
  5. hypercorn app:app --bind 0.0.0.0:8000
  6. dev:
  7. hypercorn app:app --bind 0.0.0.0:8000 --reload
  8. test:
  9. pytest tests/ -v
  10. lint:
  11. ruff check src/ tests/ app.py
  12. ruff format --check src/ tests/ app.py
  13. format:
  14. ruff check --fix src/ tests/ app.py
  15. ruff format src/ tests/ app.py
  16. clean:
  17. find . -type d -name __pycache__ -exec rm -rf {} +
  18. find . -type f -name "*.pyc" -delete
  19. rm -rf .pytest_cache htmlcov .coverage
  20. docker-build:
  21. docker build -t long-article-search-agent .
  22. docker-run:
  23. docker run --rm --env-file .env -p 8000:8000 long-article-search-agent