feat: 自动提交 - 周一 2025/09/22 15:12:38.91

This commit is contained in:
赵杰
2025-09-22 15:12:38 +01:00
parent 9306e7a401
commit b635c9e7d4
41 changed files with 7360 additions and 950 deletions

51
start_frontend.sh Normal file
View File

@@ -0,0 +1,51 @@
#!/bin/bash
echo "启动TSP智能助手前端开发服务器..."
echo
# 检查Node.js环境
echo "检查Node.js环境..."
if ! command -v node &> /dev/null; then
echo "错误: 未找到Node.js请先安装Node.js"
echo "安装命令:"
echo " Ubuntu/Debian: sudo apt update && sudo apt install nodejs npm"
echo " CentOS/RHEL: sudo yum install nodejs npm"
echo " 或访问: https://nodejs.org/"
exit 1
fi
# 检查npm环境
echo "检查npm环境..."
if ! command -v npm &> /dev/null; then
echo "错误: 未找到npm请检查Node.js安装"
exit 1
fi
echo "Node.js版本: $(node --version)"
echo "npm版本: $(npm --version)"
echo
# 进入前端目录
cd frontend
# 检查依赖包
echo "检查依赖包..."
if [ ! -d "node_modules" ]; then
echo "安装依赖包..."
npm install
if [ $? -ne 0 ]; then
echo "错误: 依赖包安装失败"
exit 1
fi
fi
echo
echo "启动开发服务器..."
echo "前端地址: http://localhost:3000"
echo "后端API: http://localhost:5000"
echo "WebSocket: ws://localhost:8765"
echo
echo "按 Ctrl+C 停止服务器"
echo
npm run dev