File size: 504 Bytes
a281c6e
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/bash
# Upload the site + sources + a compressed source archive to a Hugging Face static Space.
# The token is NEVER stored in files: export it first.
#   export HF_TOKEN=hf_xxx            (required)
#   export HF_SPACE=HelloSun/esp32emu (optional, default shown)
set -e
cd "$(dirname "$0")/.."
[ -n "$HF_TOKEN" ] || { echo "ERROR: set HF_TOKEN first (export HF_TOKEN=hf_...)"; exit 1; }
python3 tools/build_assets.py
scripts/pack_source.sh
python3 tools/deploy.py "${HF_SPACE:-HelloSun/esp32emu}"