File size: 2,305 Bytes
633f9ef |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 |
#!/bin/bash
# Hugging Face Space deployment script for Jupyter Notebook
set -e
echo "π Starting Hugging Face Space deployment..."
# Check if we're in the right directory
if [ ! -f "system_workflow_analysis.ipynb" ]; then
echo "β Error: system_workflow_analysis.ipynb not found in current directory"
exit 1
fi
# Configure git for Hugging Face
git config user.name "kenken999"
git config user.email "[email protected]"
# Check git status
echo "π Current git status:"
git status
# Add files if not already staged
if git diff --cached --quiet; then
echo "π Staging files..."
git add system_workflow_analysis.ipynb
else
echo "β
Files already staged"
fi
# Create commit if there are changes
if ! git diff --cached --quiet; then
echo "πΎ Creating commit..."
git commit -m "Add comprehensive system workflow analysis Jupyter notebook
Features:
- Complex system workflow visualization with Mermaid diagrams
- Database relationship diagrams (ERD)
- GitHub API integration flow
- Google Chat notification workflow
- Complete approval system workflow
- Real-time system monitoring capabilities
- Interactive controls for system management
This notebook provides comprehensive visualization and analysis
of the automated system generation and approval workflow."
else
echo "β
No changes to commit"
fi
# Try to push with credential helper
echo "π Attempting to push to Hugging Face Space..."
# Method 1: Try direct push
if git push origin main 2>/dev/null; then
echo "β
Successfully pushed to Hugging Face Space!"
echo "π Notebook available at: https://huggingface.co/spaces/kenken999/fastapi_django_main_live/blob/main/system_workflow_analysis.ipynb"
exit 0
fi
echo "β Direct push failed. The notebook has been committed locally."
echo "π Manual steps needed:"
echo "1. Go to https://huggingface.co/spaces/kenken999/fastapi_django_main_live"
echo "2. Upload the system_workflow_analysis.ipynb file manually"
echo "3. Or configure your Hugging Face token for git authentication"
echo "π‘ To set up git authentication with Hugging Face:"
echo " git remote set-url origin https://USER:[email protected]/spaces/kenken999/fastapi_django_main_live"
echo " (Replace USER with your username and TOKEN with your HF token)"
|