mirror of
https://github.com/kbenestad/ClubLedger.git
synced 2026-06-18 09:44:33 +00:00
Existing .venv without packages caused ModuleNotFoundError. pip install is a no-op when everything is already up to date, so always running it is safe and ensures deps are present. https://claude.ai/code/session_01JuRTR5Xjx8emQsyerBgGU7
14 lines
325 B
Bash
14 lines
325 B
Bash
#!/bin/bash
|
||
# Run ClubLedger – creates a virtualenv if needed, ensures deps are installed, starts the server.
|
||
set -e
|
||
|
||
VENV=".venv"
|
||
|
||
if [ ! -d "$VENV" ]; then
|
||
echo "Creating virtual environment..."
|
||
python3 -m venv "$VENV"
|
||
fi
|
||
|
||
"$VENV/bin/pip" install --quiet -r requirements.txt
|
||
|
||
exec "$VENV/bin/python" main.py "$@"
|