Files
yourpart3/run-bisaya-content-script.sh
Torsten Schulz (local) 4e5ddc8027 Enhance VocabLessonView and VocabService for grammar exercise handling
- Added logic to initialize grammar exercises directly from lesson data or load them separately if not included.
- Introduced a new method to initialize answer arrays for gap fill exercises, improving user interaction and response tracking.
- Updated comments for clarity on the exercise loading process and initialization logic.
2026-01-19 15:33:15 +01:00

45 lines
1.1 KiB
Bash
Executable File

#!/bin/bash
# Script zum Ausführen des Bisaya-Content-Scripts auf dem Server
# Verwendung: ./run-bisaya-content-script.sh [server_ip] [ssh_user]
set -euo pipefail
SERVER_IP="${1:-your-part.de}"
SSH_USER="${2:-root}"
echo "🚀 Führe Bisaya-Content-Script auf Server aus..."
echo "Server: $SERVER_IP"
echo "SSH User: $SSH_USER"
echo ""
ssh "$SSH_USER@$SERVER_IP" << 'EOF'
set -euo pipefail
cd /opt/yourpart/backend
echo "📋 Prüfe ob Script vorhanden ist..."
if [ ! -f "scripts/create-bisaya-course-content.js" ]; then
echo "❌ Script nicht gefunden: scripts/create-bisaya-course-content.js"
echo " Bitte zuerst Backend deployen!"
exit 1
fi
echo "✅ Script gefunden"
echo ""
echo "🔧 Führe Script aus..."
echo ""
# Führe Script als yourpart-Benutzer aus
sudo -u yourpart node scripts/create-bisaya-course-content.js
echo ""
echo "✅ Script erfolgreich ausgeführt!"
EOF
echo ""
echo "🎉 Fertig! Die Grammatik-Übungen wurden auf dem Server erstellt."
echo ""
echo "💡 Nächste Schritte:"
echo " 1. Frontend neu bauen und deployen (falls noch nicht geschehen)"
echo " 2. Browser-Cache leeren und Seite neu laden"