Use rich for table output; add uv project setup

- Replace manual column-width formatting with rich.Table
- Add pyproject.toml, uv.lock for dependency management
- Add .python-version (3.11) and .envrc for direnv/uv auto-setup
- Add main.py scaffold

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-24 20:34:19 +08:00
parent 929b7a4cec
commit e10563b405
6 changed files with 267 additions and 10 deletions

15
.envrc Normal file
View File

@@ -0,0 +1,15 @@
export PATH="/opt/homebrew/bin:$PATH"
# 建 .venv第一次用
if [ ! -d ".venv" ]; then
uv venv
fi
# 啟用direnv 用 PATH 方式)
export VIRTUAL_ENV="$PWD/.venv"
export PATH="$VIRTUAL_ENV/bin:$PATH"
# 有 pyproject.toml 就裝套件
if [ -f "pyproject.toml" ]; then
uv sync
fi