-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup-deployment.bat
More file actions
54 lines (48 loc) · 1.31 KB
/
setup-deployment.bat
File metadata and controls
54 lines (48 loc) · 1.31 KB
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
@echo off
REM Quick deployment helper script for Windows
REM Run this after deploying your backend server to Render/Railway
echo.
echo 🚀 Asterocks Deployment Helper
echo ================================
echo.
REM Get backend URL from user
echo Step 1: What is your backend server URL?
echo Example: asterocks-server.onrender.com
echo asterocks-server.up.railway.app
echo.
set /p BACKEND_URL="Backend URL (without https://): "
if "%BACKEND_URL%"=="" (
echo ❌ No URL provided. Exiting.
exit /b 1
)
echo.
echo Step 2: Updating config.js...
REM Update config.js
(
echo // Asterocks Configuration
echo // Auto-generated by deployment helper
echo.
echo window.ASTEROCKS_CONFIG = {
echo // Backend WebSocket Server
echo BACKEND_SERVER: '%BACKEND_URL%',
echo.
echo // Debug mode - set to true to see connection details in console
echo DEBUG: false
echo };
) > public\config.js
echo ✅ Configuration updated!
echo.
echo Step 3: Review changes
echo File: public\config.js
echo Backend URL: %BACKEND_URL%
echo.
echo Step 4: Commit and push to deploy
echo Run:
echo git add public\config.js
echo git commit -m "Configure backend server"
echo git push origin main
echo.
echo 🎮 After pushing, your game will auto-deploy to GitHub Pages!
echo Visit: https://YOUR-USERNAME.github.io/asterocks
echo.
pause