SpaceNinjaServer/UPDATE AND START SERVER.bat
Animan8000 f551f354fc
Updating script for dummies
- Added some empty lines to make the console look little bit cleaner and less messy
- Added text when it starts building the files and when the server actually starts
- On error the window title gets changed ("Error - SpaceNinjaServer") and the color of the console turns red (though I can remove the color, if it's unhelpful/annoying), so that any idiot realizes immediately when something went wrong

See screenshot for comparison
2025-01-20 13:20:07 +01:00

35 lines
465 B
Batchfile

@echo off
echo Updating SpaceNinjaServer...
echo.
git pull
echo.
if exist static\data\0\ (
echo Updating stripped assets...
cd static\data\0\
echo.
git pull
echo.
cd ..\..\..\
)
echo Updating dependencies...
call npm i
echo.
echo Building files...
call npm run build
echo Starting SpaceNinjaServer...
call npm run start
echo.
echo.
title Error - SpaceNinjaServer
color 0C
echo SpaceNinjaServer seems to have crashed.
:crashMsg
pause > nul
goto crashMsg