Files
remoteturtle/start.bat

70 lines
1.6 KiB
Batchfile
Raw Permalink Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
@echo off
echo 🐢 Turtle Control Center - Setup ^& Start
echo ========================================
echo.
REM Check if Node.js is installed
where node >nul 2>nul
if %ERRORLEVEL% NEQ 0 (
echo ❌ Node.js is not installed. Please install Node.js 18+ first.
echo Visit: https://nodejs.org/
pause
exit /b 1
)
echo ✅ Node.js is installed
node --version
echo.
REM Install server dependencies
echo 📦 Installing server dependencies...
cd server
if not exist "node_modules\" (
call npm install
if %ERRORLEVEL% NEQ 0 (
echo ❌ Failed to install server dependencies
pause
exit /b 1
)
) else (
echo Dependencies already installed (skipping)
)
cd ..
REM Install client dependencies
echo 📦 Installing client dependencies...
cd client
if not exist "node_modules\" (
call npm install
if %ERRORLEVEL% NEQ 0 (
echo ❌ Failed to install client dependencies
pause
exit /b 1
)
) else (
echo Dependencies already installed (skipping)
)
cd ..
echo.
echo ✨ Setup complete!
echo.
echo 🚀 Starting servers...
echo.
echo Server will be available at:
echo 🌐 Web Interface: http://localhost:3000
echo 📡 API Server: http://localhost:3001
echo 🔌 WebSocket: ws://localhost:3002
echo.
echo Press Ctrl+C to stop all servers
echo.
REM Start both servers
start "Turtle Control Server" cmd /k "cd server && npm start"
timeout /t 2 /nobreak >nul
start "Turtle Control Client" cmd /k "cd client && npm run dev"
echo.
echo ✅ Both servers are starting in separate windows
pause