#!/bin/bash
watch_file "pyproject.toml" "uv.toml" "uv.lock"
if [[ ! -f ".venv/bin/activate" ]]; then
  uv sync --all-extras --all-groups
fi
# shellcheck disable=SC2016
sd '^(\s*)?(?P<key>include-system-site-packages)(\s*)?=(\s*)?(?<val>.*)$' '$key = true' .venv/pyvenv.cfg
# shellcheck disable=SC1091
source .venv/bin/activate

DEEPSEEK_API_KEY="$(rbw get --field API_KEY DeepSeek)"
export DEEPSEEK_API_KEY
