alle Default files rein
This commit is contained in:
23
bin/install_py.sh
Normal file
23
bin/install_py.sh
Normal file
@@ -0,0 +1,23 @@
|
||||
#!/usr/bin/env bash
|
||||
# ================================================================
|
||||
# PLANTPLAN - Python Virtual Environment einrichten
|
||||
# ================================================================
|
||||
# Erstellt .venv und installiert Abhängigkeiten aus requirements.txt
|
||||
# ================================================================
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
source "$SCRIPT_DIR/setenv.sh"
|
||||
|
||||
if [ ! -d "$PROJECT/.venv" ]; then
|
||||
echo "Initialisiere Python virtual environment..."
|
||||
python3 -m venv "$PROJECT/.venv" --upgrade-deps
|
||||
echo "Erfolgreich."
|
||||
|
||||
source "$PROJECT/.venv/bin/activate"
|
||||
echo "Installiere erforderliche Python Packages..."
|
||||
pip install -r "$PROJECT/requirements.txt" -q
|
||||
echo "Erfolgreich."
|
||||
deactivate
|
||||
else
|
||||
echo "Erforderliche Python Packages bereits installiert!"
|
||||
fi
|
||||
Reference in New Issue
Block a user