Spaces:
Running
on
Zero
Running
on
Zero
| @echo off | |
| echo ============================================ | |
| echo HuggingFace Spaces Deployment Script | |
| echo ============================================ | |
| echo. | |
| REM Check if Git is installed | |
| where git >nul 2>nul | |
| if %ERRORLEVEL% NEQ 0 ( | |
| echo ERROR: Git is not installed or not in PATH | |
| echo Please install Git from: https://git-scm.com/download/win | |
| pause | |
| exit /b 1 | |
| ) | |
| REM Check if HuggingFace CLI is installed | |
| where huggingface-cli >nul 2>nul | |
| if %ERRORLEVEL% NEQ 0 ( | |
| echo HuggingFace CLI not found. Installing... | |
| pip install huggingface_hub | |
| ) | |
| echo. | |
| echo Step 1: Login to HuggingFace | |
| echo ============================= | |
| echo You'll need your HuggingFace token from: | |
| echo https://huggingface.co/settings/tokens | |
| echo. | |
| huggingface-cli login | |
| echo. | |
| echo Step 2: Enter Space Name | |
| echo ======================== | |
| set /p SPACE_NAME="Enter your Space name (e.g., ace-step-custom): " | |
| echo. | |
| echo Step 3: Creating Space... | |
| echo ========================= | |
| huggingface-cli repo create %SPACE_NAME% --type space --space_sdk gradio | |
| echo. | |
| echo Step 4: Uploading Files... | |
| echo ========================== | |
| huggingface-cli upload %SPACE_NAME% . --repo-type space --exclude ".git/*" --exclude "__pycache__/*" --exclude "*.pyc" --exclude "outputs/*" --exclude "timelines/*" --exclude "lora_training/*" --exclude "models/*" --exclude "logs/*" | |
| echo. | |
| echo ============================================ | |
| echo Deployment Complete! | |
| echo ============================================ | |
| echo. | |
| echo Your Space is being built at: | |
| echo https://huggingface.co/spaces/%USERNAME%/%SPACE_NAME% | |
| echo. | |
| echo Next steps: | |
| echo 1. Visit your Space URL | |
| echo 2. Go to Settings and enable GPU (A10G Small recommended) | |
| echo 3. Wait for build to complete (5-10 minutes) | |
| echo 4. Test all three tabs | |
| echo. | |
| echo For detailed instructions, see DEPLOYMENT.md | |
| echo. | |
| pause | |