forked from xuanyustudio/LocalMiniDrama
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun_dev.bat
More file actions
23 lines (18 loc) · 766 Bytes
/
Copy pathrun_dev.bat
File metadata and controls
23 lines (18 loc) · 766 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
@echo off
set ROOT=%~dp0
echo [0/2] Checking port 5679...
netstat -ano > "%TEMP%\lmd_netstat.txt" 2>&1
findstr ":5679 " "%TEMP%\lmd_netstat.txt" | findstr "LISTENING" > "%TEMP%\lmd_port.txt" 2>&1
for /f "tokens=5" %%a in (%TEMP%\lmd_port.txt) do (
echo Killing old process on port 5679 ^(PID %%a^)...
taskkill /PID %%a /F >nul 2>&1
)
del "%TEMP%\lmd_netstat.txt" >nul 2>&1
del "%TEMP%\lmd_port.txt" >nul 2>&1
echo [1/2] Starting backend (backend-node)...
start "Backend" cmd /k "cd /d %ROOT%backend-node && npm run dev"
echo [2/2] Starting frontend (frontweb)...
start "Frontend" cmd /k "cd /d %ROOT%frontweb && npm run dev"
echo Done. Backend: http://127.0.0.1:3013 Frontend: http://127.0.0.1:5173
timeout /t 3 /nobreak >nul
start http://127.0.0.1:3013