test2:
    uv run pytest

fixtest: fix test

test:
    uv run pytest --cov src/remedapy --cov-report=term-missing --cov-fail-under=100

build:
    rm -fr dist && uv build

tag:
    # git tag $(uv version | tail -n 1 | cut -d " " -f2)

publish: check build tag
    uv publish --index testpypi

publish-pypi: check build tag
    uv publish

format:
    ruff format src

isort *flags:
    ruff check --select I {{flags}}

lint *flags:
    ruff check src --preview {{flags}}

markdownlint *flags:
    markdownlint-cli2 "**/*.md" {{flags}}

pyright:
    basedpyright src

bump:
    uv version --bump patch

typos *flags:
    typos {{flags}}

fix: typos (markdownlint "--fix") format (isort "--fix") (lint "--fix") pyright 

check: typos markdownlint format isort lint pyright 

generate_readme:
    uv run python readme_generation/generate.py
    just markdownlint "--fix"
# TODO: check if generate_readme changes readme
