Commit Graph
18 Commits
Author SHA1 Message Date
fenghpandCursor 24de23ee61 feat: 增加父进程看护机制与操作来源标识
- 新增 startParentWatchdog 方法,监控宿主进程状态,确保后端在宿主崩溃时自动退出,避免端口占用。
- 在 API 请求中引入 X-MacTFS-Source 请求头,区分来自 MCP(AI)与手动操作的请求,增强操作日志的可追溯性。
- 更新操作日志结构,记录操作来源,支持在前端进行来源过滤展示。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-26 14:15:08 +08:00
fenghpandCursor b03ca2c4d5 fix: 补上 main.cjs 缺失的 MCP_HOST 常量,修复打包版主进程启动崩溃
新增的 MCP_SSE_URL / MCP_HEALTHZ_URL 引用了未定义的 MCP_HOST,
导致主进程模块加载即抛 ReferenceError(开发态未触发,仅安装版暴露)。
补上 const MCP_HOST = "127.0.0.1"。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-23 11:25:23 +08:00
fenghpandCursor 03eb61520f build: 将 mactfs-mcp 以 esbuild 单文件打进 .app
- mactfs-mcp 增加 esbuild 与 build:bundle 脚本,产出单文件 dist-bundle/index.cjs
  (免带 node_modules),用 .cjs 规避 type:module 下的 ESM 误判
- mactfsui extraResources 增加 { from: ../mactfs-mcp/dist-bundle, to: mcp },
  dist 链路加入 prepare:mcp(自动 install + build:bundle)
- Electron resolveMcpEntry 打包态改为命中 Resources/mcp/index.cjs
- 同步更新 mactfs-mcp/README 与打包构建文档(移除「MCP 未打进 .app」的旧限制)

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-23 11:17:00 +08:00
fenghpandCursor 9018a6c90e feat: 顶栏新增 TFS 连接测试与 MCP 状态/日志查看
- 后端新增只读端点 POST /api/session/test:用已存配置真正回连一次 TFS,
  验证服务可达与认证有效,不改动会话/配置状态,返回耗时与 Collection 数
- 顶栏加「测试 TFS 连接」按钮:手动触发,图标按结果变色(绿=正常/红=断开),
  结果走右上角 toast
- Electron 将 MCP 子进程 stdio 由 ignore 改为管道捕获,环形缓冲保留最近 500 行;
  跟踪运行状态(pid/运行时长/重启次数/退出码)并探活 /healthz,新增 get-mcp-status
  / get-mcp-logs 两个 IPC,经 preload 与 lib/electron 暴露
- 顶栏加「MCP 服务状态」入口,新增 McpStatusDialog 展示状态摘要与运行日志
  (打开期间每 2 秒刷新、自动滚到底部)

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-23 11:05:19 +08:00
fenghpandCursor e9f942e695 feat: 新增 mactfs-mcp 服务(AI 改文件前自动签出/加入)
- mactfs-mcp:通过 SSE 暴露 tfs_checkout / tfs_add,转调本机 Java 后端操作 TFS
- 后端 MacTfsCoreService/MacTfsServer 新增文件状态查询等接口,供 MCP 执行前校验
- Electron 随客户端拉起并回收 MCP 子进程(父死自杀、崩溃自动重拉)
- tfs_checkout 默认行为:新文件自动 add、本地落后自动 get-latest 后再签出
  (可分别用 autoAdd=false / getLatestIfStale=false 关闭;dryRun 无副作用)
- 新增 docs/打包构建与MCP使用指南.md

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-23 10:31:31 +08:00
fenghpandCursor b2b2f49db6 chore: 将 main 整棵树对齐到 feature 分支(移除并行分支遗留文件与重复声明,确保可构建)
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-16 14:37:39 +08:00
fenghp a107ec1f2c Merge feature/ui-macos-restyle into main
合并 macOS 原生风 UI 改版分支,冲突以 feature 分支为准
(feature 为当前维护主线,取代 main 上的并行前端尝试)。

Co-authored-by: Cursor <cursoragent@cursor.com>

# Conflicts:
#	task/frontend/FE-001-实现Electron启动服务与API客户端.md
#	task/frontend/FE-002-实现登录配置页.md
#	task/frontend/FE-003-实现VS风格主布局.md
#	task/frontend/FE-004-实现Collection服务端目录树.md
#	task/frontend/FE-005-实现中间目录文件列表.md
#	task/frontend/FE-006-实现Mapping创建流程.md
#	task/frontend/FE-007-实现目录对比页面.md
#	task/frontend/FE-008-实现右侧挂起更改面板.md
#	task/frontend/FE-009-实现文件操作交互.md
#	task/frontend/FE-010-实现签入流程.md
#	task/frontend/FE-011-实现历史记录界面.md
#	task/frontend/FE-012-实现文件Diff界面.md
#	task/frontend/FE-013-实现操作日志面板.md
2026-06-16 14:33:47 +08:00
fenghpandCursor e1a5793a62 release: Electron打包(electron-builder) + JDK运行时按需从Azul下载
- mactfsui 增加 electron-builder 配置与 dist/prepare:runtime 脚本,打包 universal DMG,服务端随 extraResources 内置 x64 JRE 与 jar
- main.cjs 打包态解析 jre-x64/server/lib,新增 app:// 自定义协议加载前端静态资源避免白屏
- prepare-runtime.mjs 本地无 JDK 时自动从 Azul 下载并校验 sha256 后解压,避免把 206M JDK 入库
- 整理 .gitignore:忽略 dist-app/runtime/icon.iconset 及 aarch64 JDK

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-16 12:37:10 +08:00
fenghpandCursor 08bb38b188 体验: toast改macOS通知风圆徽毛玻璃卡片,移除明暗主题切换仅保留亮色
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-12 20:15:53 +08:00
fenghpandCursor 3d1ffd0e81 frontend: FE-027 隐藏式标题栏+窗口vibrancy毛玻璃+防白闪+启动最大化+顶栏拖拽
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-11 20:07:57 +08:00
fenghpandCursor b3454eb157 品牌: 项目更名为 MacTFS,Electron 窗口与程序坞使用根目录 logo 图标
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-11 15:04:49 +08:00
fenghpandCursor fe4c573585 优化: 添加本地文件改为扫描式(FE-025修订),目录对比自动筛出本地新增项勾选添加
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-11 14:39:20 +08:00
fenghpandCursor 75c8e00e19 功能: 右键支持在访达中打开与添加本地文件到版本控制(FE-025),中间区域空白处提供当前目录菜单
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-11 14:23:13 +08:00
fenghpandCursor bbbb938df0 frontend: add lazy server tree and folder items list with synced navigation and local state badges
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-10 17:57:51 +08:00
fenghpandCursor 5c633fd024 frontend: add electron service bootstrap, preload and api client
FE-001: detect and launch the local mactfs-server, expose a narrow preload
bridge (token, service status, directory picker), and add a unified API
client that auto-attaches the Bearer token. Home becomes a bootstrap gate
with a retry entry. Update task board, FE-001 record and FRONTEND_SPEC.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-09 19:46:09 +08:00
fenghp acb388d22d 完成阶段5前端重构并固定后端JDK 2026-06-09 15:09:25 +08:00
fenghp 8692edd2dd Add frontend workspace UI and refactor plan 2026-06-09 10:07:22 +08:00
fenghp 3168897b6c chore: add mactfs planning and task workflow 2026-06-05 19:04:20 +08:00