Spaces:
Sleeping
Sleeping
Download run_dev.sh from gui-sparim/mp_tpu_TESTES: direct link, hf CLI and curl.
- Browser
- Download file 583 Bytes
-
https://huggingface.co/spaces/gui-sparim/mp_tpu_TESTES/resolve/main/run_dev.sh
- Command line
-
hf download hf://spaces/gui-sparim/mp_tpu_TESTES/run_dev.sh
-
curl -L -o run_dev.sh https://huggingface.co/spaces/gui-sparim/mp_tpu_TESTES/resolve/main/run_dev.sh
583 Bytes
| set -euo pipefail | |
| APP_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" | |
| cd "$APP_DIR" | |
| if [[ ! -x .venv/bin/uvicorn ]]; then | |
| python3 -m venv .venv | |
| .venv/bin/pip install -q -r backend/requirements-dev.txt | |
| fi | |
| if [[ ! -d frontend/node_modules ]]; then | |
| npm --prefix frontend install | |
| fi | |
| cleanup() { kill "${BACKEND_PID:-0}" 2>/dev/null || true; } | |
| trap cleanup EXIT INT TERM | |
| DATA_DIR="${DATA_DIR:-$APP_DIR/data}" .venv/bin/uvicorn backend.app.main:app --host 127.0.0.1 --port 7860 --reload & | |
| BACKEND_PID=$! | |
| npm --prefix frontend run dev -- --host 127.0.0.1 | |