Files
agent_jrxml/stop.bat
T
panda c8924c625c fix: rewrite startup scripts with reliable helpers, stderr logging, visible windows
- Replace /MIN (hidden window) with normal windows so errors are visible
- Redirect stderr to logs/*.log for post-mortem
- Extract killport/wait_health/wait_port into callable helpers
- Use !N! (delayed expansion) for retry counters
- stop.bat now shows which PIDs it kills with port labels
- Remove nested-quote issue by cd'ing before npm start
2026-05-23 09:25:45 +08:00

28 lines
871 B
Batchfile

@echo off
chcp 65001 >nul
echo ================================================
echo 停止所有 agent_jrxml 服务
echo ================================================
echo [停止] 按窗口标题清理...
taskkill /F /FI "WINDOWTITLE eq jrxml-validator*" 2>nul
taskkill /F /FI "WINDOWTITLE eq jrxml-api*" 2>nul
taskkill /F /FI "WINDOWTITLE eq jrxml-frontend*" 2>nul
echo [停止] 按端口清理...
for /f "tokens=5" %%a in ('netstat -ano ^| findstr ":8000.*LISTENING"') do (
echo 端口 8000 - PID %%a
taskkill /F /PID %%a >nul 2>&1
)
for /f "tokens=5" %%a in ('netstat -ano ^| findstr ":8001.*LISTENING"') do (
echo 端口 8001 - PID %%a
taskkill /F /PID %%a >nul 2>&1
)
for /f "tokens=5" %%a in ('netstat -ano ^| findstr ":5173.*LISTENING"') do (
echo 端口 5173 - PID %%a
taskkill /F /PID %%a >nul 2>&1
)
echo 已停止
pause