Skip to content

Latest commit

 

History

History
39 lines (31 loc) · 787 Bytes

File metadata and controls

39 lines (31 loc) · 787 Bytes

環境構築

uvをインストール: https://docs.astral.sh/uv/getting-started/installation/ もしくはnixを使う

# このテンプレートで開発する場合
uv sync

# このテンプレートを再現したい場合
uv init
uv add typer rich textual
uv add --dev ruff

main.py と textual.py を作ってコードを貼り付ける

開発用コマンド

# lint
uv run ruff check --fix
uv run ruff check --watch
# format
uv run ruff format
# type check
uvx ty
# execute
uv run main.py

備考

  • VS Code で >Python: Select Interpreter から ./.venv/bin/python を指定してパッケージを認識させる

参考

https://docs.astral.sh/uv/ https://docs.astral.sh/ruff/ https://typer.tiangolo.com/ https://rich.readthedocs.io/en/latest/