ygl-trees 0.76.1 → 0.77.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/dist/apps/cli/src/bin.js +15 -0
- package/dist/bundle/bin.cjs +171 -256
- package/dist/bundle/text-Bce0wNAD.cjs +172 -0
- package/dist/packages/ops/tools/src/plugins.js +31 -2
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.77.0(2026-10-17)plugin 安全加固 + DEP0190 消除
|
|
4
|
+
- **P0 修复**:plugin install 坏路径不再被记录——存在性校验 + package.json name 校验(a2a 7aa5c871)
|
|
5
|
+
- **P0 修复**:StartupError 时 plugin 命令走 degraded mode——坏插件不再砖死 home,plugin remove 自愈可用
|
|
6
|
+
- **P1 修复**:启动失败退出码 rc=1(修复前 rc=0,违反冻结契约)
|
|
7
|
+
- **P2 修复**:包名从 package.json 读取真实 name(不再退化为 basename)
|
|
8
|
+
- **DEP0190 消除**:pnpm spawn 改用 cmd /c 显式调用(不再传 args 给 shell:true)
|
|
9
|
+
|
|
3
10
|
## 0.76.1(2026-10-17)--ai 多 Agent 支持 + ctx.emit 桥接
|
|
4
11
|
- **skill link --ai <agent>**:一键连接到多种 AI Agent 的技能目录——pi(~/.pi/agent/skills/) · claude · cursor · windsurf · custom(--to)
|
|
5
12
|
- **ctx.emit 桥接**:eventbus 内部事件自动转发到 Cordis ctx.emit——插件可用 ctx.on("ygl") 监听(文档承诺兑现)
|
package/dist/apps/cli/src/bin.js
CHANGED
|
@@ -374,6 +374,21 @@ async function main(argv) {
|
|
|
374
374
|
}
|
|
375
375
|
catch (e) {
|
|
376
376
|
if (e instanceof startup_diagnostics_1.StartupError) {
|
|
377
|
+
// P0 fix (a2a 7aa5c871): a bad plugin entry must not brick the home —
|
|
378
|
+
// plugin remove/install must work even when other plugins fail to load.
|
|
379
|
+
// If the command is plugin-related, proceed with a degraded boot.
|
|
380
|
+
if (group === "plugin") {
|
|
381
|
+
const pluginCmds = await Promise.resolve().then(() => __importStar(require("./plugin")));
|
|
382
|
+
const { dbPath } = await Promise.resolve().then(() => __importStar(require("../../../packages/core/database/src/db")));
|
|
383
|
+
const dbFile2 = dbPath(home);
|
|
384
|
+
// Minimal env — no plugins, direct DB access
|
|
385
|
+
const env2 = {
|
|
386
|
+
home, dbFile: dbFile2, ctx,
|
|
387
|
+
db: null, store: null, cordis: null,
|
|
388
|
+
};
|
|
389
|
+
(0, fmt_1.out)(ctx, (0, fmt_1.paint)(fmt_1.C.yellow, " ! degraded mode: user plugins failed to load — plugin commands only", ctx.color));
|
|
390
|
+
return pluginCmds.runPluginCommand(env2, action || "list", args._.slice(2), args);
|
|
391
|
+
}
|
|
377
392
|
(0, startup_diagnostics_1.reportStartupFailure)(e, home, VERSION);
|
|
378
393
|
return 1;
|
|
379
394
|
}
|