Commit Graph
17 Commits
Author SHA1 Message Date
ypshidifu 028af01b3d v2: 加回全部功能 - session列表/快捷键/MCP拦截 2026-09-22 15:58:26 +08:00
ypshidifu 952b31127c v2: 简化 oc-session-all 为最小化版本测试加载 2026-09-22 15:37:54 +08:00
ypshidifu a5a8c5e011 v2: 将 oc-session-all 从 v1 格式转为 v2 Plugin.define 格式
- 使用 import { Plugin } from "@opencode/plugin/tui"
- 使用 Plugin.define({ id, setup(context) }) 格式
- api.* 调用全部替换为 context.*: api.event.on → context.data.on, api.ui.toast → context.ui.toast.show, api.ui.dialog.* → context.ui.dialog.*, api.command.register + api.keymap.registerLayer 合并为 context.keymap.layer({commands, bindings})
- package.json exports 添加 ./tui 入口点,engines.opencode 升级为 >=2.0.0
- 已通过 minimal-v2-test 验证 v2 格式可正确加载
2026-09-22 15:19:14 +08:00
ypshidifu 76d641b17f 删除错误的node_modules目录。 2026-09-22 12:07:43 +08:00
youpaishidifu 6c165dadd5 创建最小化tui.json以便测试各项功能 2026-09-22 11:59:05 +08:00
ypshidifu 47c668f446 添加调试版本插件,修改gitignore允许提交js文件 2026-09-22 11:02:38 +08:00
ypshidifu d201e3bb97 更新tui.json 2026-09-22 10:46:22 +08:00
ypshidifu 6bbbc5ea0b 更新tui.json 2026-09-22 10:27:33 +08:00
ypshidifu 258a40b0d0 整理: 删除冗余的 src/ 目录,统一入口为 tui-plugins/,更新 README 和 package.json 2026-09-21 19:41:05 +08:00
ypshidifu 6c4d97362f 整合: 将 tui-plugins 目录移入项目根目录,统一代码管理 2026-09-21 19:31:08 +08:00
ypshidifu bfe683d7e2 修复: 将TUI插件从plugins/自动发现目录移出,避免server loader报错failed, local
- 将oc-session-all.ts从plugins/移至tui-plugins/目录
- 更新tui.json引用路径为./tui-plugins/oc-session-all.ts
- 移除空的@opencode-ai/plugin/tui类型导入
- 改用api.client.experimental.session.list获取会话
- 优化MCP错误toast拦截:将error替换为info静默提示
- 同步更新源码目录src/index.ts
2026-09-21 18:58:37 +08:00
ypshidifu 37df56c6d9 重写为TUI插件:弹出面板显示所有会话,点击跳转,拦截MCP报错 2026-09-21 18:19:18 +08:00
ypshidifu 289ff13132 修复:将插件从 Tool 改为 Command,支持用户输入 /sessions-all 命令 2026-09-21 17:29:21 +08:00
ypshidifu 45e68bfecf 更新插件:使用 node:sqlite 替代 sqlite3 命令行,提高 Windows 兼容性 2026-09-21 17:21:54 +08:00
ypshidifu 0d19143065 重写插件为V2格式:使用define+id+setup(ctx)+ctx.tool.transform注册工具 2026-09-21 17:04:34 +08:00
ypshidifu 5d43b5ed76 修复:使用 OpenCode 2.x Plugin API,正确导入类型和 tool helper 2026-09-20 23:45:41 +08:00
ypshidifu 02f3ded256 初始化插件:oc-session-all - 显示所有会话记录,绕过目录过滤 2026-09-20 23:35:05 +08:00