platform-assistant/scripts/start-dev.sh
Sisyphus afac18e843 feat(F002): W26 + W29.x + W30 + W31 平台助手全部改动首次 commit
- W26: NestJS API + Next.js Web + Prisma + SQLite scaffold
- W26: Lead 模型 + Crawler + 询价发布助手 (线索池 + 一键发布)
- W29.x: MCP 集成 (Integration 模型 + connectMcp + publish_rfq 5 工具端到端跑通)
- W30: 3 字段补充 (notes / quotationType / quotationDemand)
- W31 P1: 自动填 enterpriseId / userId (Prisma companyUserId 字段 + get_app_identity tool + lead.service.ts publishArgs)
- W31: detail 详情页 + admin UI 集成管理 (OpenAppListView + AuditLogListView)

关联: ~/Documents/02-平台开发/产品开发/F002-W31-交接文档.md
GIT-AUDIT-REPORT-2026-06-24.md
2026-06-24 11:07:11 +08:00

31 lines
817 B
Bash
Executable File
Raw Blame History

This file contains ambiguous Unicode characters

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.

#!/bin/bash
# daemon 方式启动前后端 dev server,进程独立于调用者 shell
set -e
ROOT="$(cd "$(dirname "$0")/.." && pwd)"
API_PID_FILE="$ROOT/.dev-api.pid"
WEB_PID_FILE="$ROOT/.dev-web.pid"
# 清理残留
for f in "$API_PID_FILE" "$WEB_PID_FILE"; do
[ -f "$f" ] && kill $(cat "$f") 2>/dev/null; rm -f "$f"
done
cd "$ROOT/apps/api"
nohup npx nest start --watch > /tmp/api-dev.log 2>&1 &
API_PID=$!
echo $API_PID > "$API_PID_FILE"
cd "$ROOT/apps/web"
nohup npx next dev -p 3001 > /tmp/web-dev.log 2>&1 &
WEB_PID=$!
echo $WEB_PID > "$WEB_PID_FILE"
echo "后端已启动 (PID $API_PID) - 日志: /tmp/api-dev.log"
echo "前端已启动 (PID $WEB_PID) - 日志: /tmp/web-dev.log"
echo ""
echo "前端: http://localhost:3001"
echo "后端: http://localhost:4000"
echo ""
echo "停止: npm run dev:stop"