@ken-jo/agent-connector 0.4.75 → 0.4.91
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/README.md +3 -3
- package/dist/{action-TCKBTTZX.js → action-L44DXFHT.js} +14 -14
- package/dist/{amazon-q-CB4XFX7T.js → amazon-q-B52EY2SV.js} +5 -5
- package/dist/{amp-6Q5OYHNW.js → amp-UXABVUKC.js} +5 -5
- package/dist/{antigravity-WIK3XBN5.js → antigravity-RZHN53VB.js} +6 -6
- package/dist/antigravity-cli-JO6GUTV7.js +436 -0
- package/dist/antigravity-cli-JO6GUTV7.js.map +1 -0
- package/dist/{chunk-Q5LECKZL.js → chunk-25CPWJA7.js} +116 -36
- package/dist/chunk-25CPWJA7.js.map +1 -0
- package/dist/{chunk-D6ZJS4ND.js → chunk-4FWETID5.js} +2 -2
- package/dist/{chunk-Q42SEI7W.js → chunk-4HVQ7IUM.js} +3 -3
- package/dist/{chunk-IU42THN7.js → chunk-4NSU3KWX.js} +2 -2
- package/dist/{chunk-7CZKXXBD.js → chunk-56R2ER7K.js} +2 -2
- package/dist/{chunk-HKM3HUOK.js → chunk-7HUUINPB.js} +18 -18
- package/dist/{chunk-TZ5KGCE2.js → chunk-AY3RGRTT.js} +2 -2
- package/dist/{chunk-MHDQWZ4A.js → chunk-BLTVZACS.js} +23 -13
- package/dist/chunk-BLTVZACS.js.map +1 -0
- package/dist/{chunk-7ITLLYWB.js → chunk-G4CEELKO.js} +5 -5
- package/dist/{chunk-TO57WYBB.js → chunk-HORHRHNG.js} +9 -3
- package/dist/chunk-HORHRHNG.js.map +1 -0
- package/dist/{chunk-2HCJV6UO.js → chunk-IXOQDZWC.js} +9 -2
- package/dist/chunk-IXOQDZWC.js.map +1 -0
- package/dist/{chunk-2L6LTQ6L.js → chunk-KIRCPLM4.js} +21 -10
- package/dist/chunk-KIRCPLM4.js.map +1 -0
- package/dist/{chunk-24K6JOKV.js → chunk-LAIITCMW.js} +8 -8
- package/dist/{chunk-OEQJGBBW.js → chunk-LF76VPGQ.js} +9 -9
- package/dist/{chunk-7QRUZAUG.js → chunk-LN76OGNR.js} +2 -2
- package/dist/{chunk-DI6OWKH2.js → chunk-NBUEL74R.js} +3 -3
- package/dist/{chunk-IRUYJD23.js → chunk-NLE2J5P4.js} +1 -1
- package/dist/{chunk-5LAFKXFM.js → chunk-NWLRJNXM.js} +3 -3
- package/dist/{chunk-ECSRTK4M.js → chunk-QARPXSIV.js} +4 -4
- package/dist/{chunk-AXAHW2KU.js → chunk-QKLJU4JX.js} +2 -2
- package/dist/{chunk-MDZG5QHB.js → chunk-R6LML2YS.js} +2 -2
- package/dist/{chunk-FUXUEXDP.js → chunk-UBB7T54N.js} +3 -3
- package/dist/{chunk-NUGMVVV2.js → chunk-VVFDU4IX.js} +4 -4
- package/dist/{chunk-ALVXORZM.js → chunk-YYNXIUR2.js} +2 -2
- package/dist/{chunk-TW4DVR4V.js → chunk-ZMLVR4J7.js} +7 -2
- package/dist/chunk-ZMLVR4J7.js.map +1 -0
- package/dist/{claude-code-HFBAAVWS.js → claude-code-WS4NAGZT.js} +9 -9
- package/dist/cli/sdk.js +7 -7
- package/dist/cli.js +1 -1
- package/dist/{cline-26W4FEZ6.js → cline-NNMVCECA.js} +5 -5
- package/dist/codebuddy-RBEZGXBG.js +643 -0
- package/dist/codebuddy-RBEZGXBG.js.map +1 -0
- package/dist/{codebuff-J5KEEBIL.js → codebuff-RJIDSEU3.js} +5 -5
- package/dist/{codex-JKQ6TLRI.js → codex-ZZ434GYR.js} +8 -8
- package/dist/{continue-KQSJUSWX.js → continue-MNM7YVJY.js} +6 -6
- package/dist/{copilot-cli-YBNKLYUB.js → copilot-cli-SMTX5F65.js} +5 -5
- package/dist/{crush-JTWTZIPB.js → crush-NYDBHIJE.js} +5 -5
- package/dist/{cursor-2NIZSDZ4.js → cursor-AOELDNZU.js} +6 -6
- package/dist/{detect-CWEIQCRC.js → detect-3S46RUMK.js} +4 -4
- package/dist/devin-PRJY2TTD.js +510 -0
- package/dist/devin-PRJY2TTD.js.map +1 -0
- package/dist/{doctor-AC437ZAW.js → doctor-3CUBPQKU.js} +22 -22
- package/dist/{droid-HF2AIFB2.js → droid-PTCH2K7Y.js} +5 -5
- package/dist/{gemini-cli-2EOK26S2.js → gemini-cli-QGLN2UMS.js} +5 -5
- package/dist/{goose-55JOTXS5.js → goose-DQ6GSZ5O.js} +6 -6
- package/dist/grok-cli-5QD235UB.js +482 -0
- package/dist/grok-cli-5QD235UB.js.map +1 -0
- package/dist/{hermes-QVZOZU4B.js → hermes-E47IG63A.js} +6 -6
- package/dist/{hook-VYD3OCLM.js → hook-P6EKDINW.js} +14 -14
- package/dist/index.d.ts +2 -2
- package/dist/index.js +5 -5
- package/dist/{install-S6BYIJ62.js → install-7DMK53SB.js} +18 -18
- package/dist/{introspect-5o5ick0_.d.ts → introspect-DYOIX8Ov.d.ts} +1 -1
- package/dist/{jetbrains-copilot-DZ2ATXFN.js → jetbrains-copilot-T2EPKROP.js} +13 -7
- package/dist/jetbrains-copilot-T2EPKROP.js.map +1 -0
- package/dist/junie-SQ4SDLGK.js +227 -0
- package/dist/junie-SQ4SDLGK.js.map +1 -0
- package/dist/{kilo-GJNSBWVV.js → kilo-OU2ZLZKB.js} +8 -8
- package/dist/{kilo-cli-2CCB3DBI.js → kilo-cli-NMWGYF4F.js} +8 -8
- package/dist/{kimi-YRPCSB6N.js → kimi-Z7L2LEEI.js} +5 -5
- package/dist/{kiro-BUOQFASX.js → kiro-4IN5IH46.js} +81 -6
- package/dist/kiro-4IN5IH46.js.map +1 -0
- package/dist/{leaderboard-SUSUDKHR.js → leaderboard-LF5SP6X2.js} +7 -7
- package/dist/{mimo-code-V4FP5PUJ.js → mimo-code-G2CBZ4M6.js} +5 -5
- package/dist/mistral-vibe-TRQDHAWV.js +300 -0
- package/dist/mistral-vibe-TRQDHAWV.js.map +1 -0
- package/dist/{mux-CMJSM42O.js → mux-JNM3F2NW.js} +5 -5
- package/dist/{nemoclaw-VP56PGKC.js → nemoclaw-SHA4IUML.js} +6 -6
- package/dist/{omp-OOFGD3GG.js → omp-OOVUNXME.js} +5 -5
- package/dist/open-interpreter-4PKL56AA.js +264 -0
- package/dist/open-interpreter-4PKL56AA.js.map +1 -0
- package/dist/openclaw-BD56E5MV.js +17 -0
- package/dist/{opencode-MKLHSQRD.js → opencode-W2RK4M7G.js} +5 -5
- package/dist/openhands-5LNH3BKB.js +384 -0
- package/dist/openhands-5LNH3BKB.js.map +1 -0
- package/dist/{package-KOAAVKHH.js → package-2EAIYSJ4.js} +13 -13
- package/dist/{pi-NMVL7OFL.js → pi-BUADR5MJ.js} +143 -6
- package/dist/pi-BUADR5MJ.js.map +1 -0
- package/dist/{qwen-code-2XE2T6F4.js → qwen-code-TUJNHKNI.js} +9 -9
- package/dist/{roo-code-YJOIKCCS.js → roo-code-L5F7S6QH.js} +5 -5
- package/dist/runtime/index.d.ts +12 -1
- package/dist/runtime/index.js +12 -12
- package/dist/sdk/index.d.ts +3 -3
- package/dist/sdk/index.js +6 -6
- package/dist/sdk/test.d.ts +2 -2
- package/dist/sdk/test.js +10 -10
- package/dist/{serve-BU23QUSJ.js → serve-K62FW3V7.js} +24 -17
- package/dist/serve-K62FW3V7.js.map +1 -0
- package/dist/{status-N5LCQQ3R.js → status-E5MCFZM6.js} +11 -11
- package/dist/{statusline-442XOF7R.js → statusline-LIPF2KVP.js} +13 -13
- package/dist/{telemetry-V4YQL2NU.js → telemetry-4OC56NTM.js} +10 -10
- package/dist/{trae-QSV2JZFT.js → trae-Z7CQ2A2Q.js} +5 -5
- package/dist/{types-D6RWGXm1.d.ts → types-C4qMgbJn.d.ts} +10 -9
- package/dist/{uninstall-WGEKTCDZ.js → uninstall-2YYKN5DX.js} +18 -18
- package/dist/{upgrade-IH7CKPTO.js → upgrade-55AFPJEF.js} +18 -18
- package/dist/{usage-DI7XRCKM.js → usage-3PB3WZSL.js} +3 -3
- package/dist/{usage-event-2FCU55AN.js → usage-event-KD5FW6W4.js} +13 -13
- package/dist/{vscode-copilot-R23RTVST.js → vscode-copilot-LU5NC4ZS.js} +5 -5
- package/dist/{warp-B72XSQ5G.js → warp-4PPG5LOM.js} +5 -5
- package/dist/{windsurf-642VBMQ2.js → windsurf-3T3RVXKM.js} +5 -5
- package/dist/{zed-6UJS7JKB.js → zed-ZF2OQ75O.js} +123 -7
- package/dist/zed-ZF2OQ75O.js.map +1 -0
- package/package.json +1 -1
- package/dist/antigravity-cli-L3RZMF6V.js +0 -87
- package/dist/antigravity-cli-L3RZMF6V.js.map +0 -1
- package/dist/chunk-2HCJV6UO.js.map +0 -1
- package/dist/chunk-2L6LTQ6L.js.map +0 -1
- package/dist/chunk-MHDQWZ4A.js.map +0 -1
- package/dist/chunk-Q5LECKZL.js.map +0 -1
- package/dist/chunk-TO57WYBB.js.map +0 -1
- package/dist/chunk-TW4DVR4V.js.map +0 -1
- package/dist/jetbrains-copilot-DZ2ATXFN.js.map +0 -1
- package/dist/kiro-BUOQFASX.js.map +0 -1
- package/dist/openclaw-V73XHPXP.js +0 -17
- package/dist/pi-NMVL7OFL.js.map +0 -1
- package/dist/serve-BU23QUSJ.js.map +0 -1
- package/dist/zed-6UJS7JKB.js.map +0 -1
- /package/dist/{action-TCKBTTZX.js.map → action-L44DXFHT.js.map} +0 -0
- /package/dist/{amazon-q-CB4XFX7T.js.map → amazon-q-B52EY2SV.js.map} +0 -0
- /package/dist/{amp-6Q5OYHNW.js.map → amp-UXABVUKC.js.map} +0 -0
- /package/dist/{antigravity-WIK3XBN5.js.map → antigravity-RZHN53VB.js.map} +0 -0
- /package/dist/{chunk-D6ZJS4ND.js.map → chunk-4FWETID5.js.map} +0 -0
- /package/dist/{chunk-Q42SEI7W.js.map → chunk-4HVQ7IUM.js.map} +0 -0
- /package/dist/{chunk-IU42THN7.js.map → chunk-4NSU3KWX.js.map} +0 -0
- /package/dist/{chunk-7CZKXXBD.js.map → chunk-56R2ER7K.js.map} +0 -0
- /package/dist/{chunk-HKM3HUOK.js.map → chunk-7HUUINPB.js.map} +0 -0
- /package/dist/{chunk-TZ5KGCE2.js.map → chunk-AY3RGRTT.js.map} +0 -0
- /package/dist/{chunk-7ITLLYWB.js.map → chunk-G4CEELKO.js.map} +0 -0
- /package/dist/{chunk-24K6JOKV.js.map → chunk-LAIITCMW.js.map} +0 -0
- /package/dist/{chunk-OEQJGBBW.js.map → chunk-LF76VPGQ.js.map} +0 -0
- /package/dist/{chunk-7QRUZAUG.js.map → chunk-LN76OGNR.js.map} +0 -0
- /package/dist/{chunk-DI6OWKH2.js.map → chunk-NBUEL74R.js.map} +0 -0
- /package/dist/{chunk-IRUYJD23.js.map → chunk-NLE2J5P4.js.map} +0 -0
- /package/dist/{chunk-5LAFKXFM.js.map → chunk-NWLRJNXM.js.map} +0 -0
- /package/dist/{chunk-ECSRTK4M.js.map → chunk-QARPXSIV.js.map} +0 -0
- /package/dist/{chunk-AXAHW2KU.js.map → chunk-QKLJU4JX.js.map} +0 -0
- /package/dist/{chunk-MDZG5QHB.js.map → chunk-R6LML2YS.js.map} +0 -0
- /package/dist/{chunk-FUXUEXDP.js.map → chunk-UBB7T54N.js.map} +0 -0
- /package/dist/{chunk-NUGMVVV2.js.map → chunk-VVFDU4IX.js.map} +0 -0
- /package/dist/{chunk-ALVXORZM.js.map → chunk-YYNXIUR2.js.map} +0 -0
- /package/dist/{claude-code-HFBAAVWS.js.map → claude-code-WS4NAGZT.js.map} +0 -0
- /package/dist/{cline-26W4FEZ6.js.map → cline-NNMVCECA.js.map} +0 -0
- /package/dist/{codebuff-J5KEEBIL.js.map → codebuff-RJIDSEU3.js.map} +0 -0
- /package/dist/{codex-JKQ6TLRI.js.map → codex-ZZ434GYR.js.map} +0 -0
- /package/dist/{continue-KQSJUSWX.js.map → continue-MNM7YVJY.js.map} +0 -0
- /package/dist/{copilot-cli-YBNKLYUB.js.map → copilot-cli-SMTX5F65.js.map} +0 -0
- /package/dist/{crush-JTWTZIPB.js.map → crush-NYDBHIJE.js.map} +0 -0
- /package/dist/{cursor-2NIZSDZ4.js.map → cursor-AOELDNZU.js.map} +0 -0
- /package/dist/{detect-CWEIQCRC.js.map → detect-3S46RUMK.js.map} +0 -0
- /package/dist/{doctor-AC437ZAW.js.map → doctor-3CUBPQKU.js.map} +0 -0
- /package/dist/{droid-HF2AIFB2.js.map → droid-PTCH2K7Y.js.map} +0 -0
- /package/dist/{gemini-cli-2EOK26S2.js.map → gemini-cli-QGLN2UMS.js.map} +0 -0
- /package/dist/{goose-55JOTXS5.js.map → goose-DQ6GSZ5O.js.map} +0 -0
- /package/dist/{hermes-QVZOZU4B.js.map → hermes-E47IG63A.js.map} +0 -0
- /package/dist/{hook-VYD3OCLM.js.map → hook-P6EKDINW.js.map} +0 -0
- /package/dist/{install-S6BYIJ62.js.map → install-7DMK53SB.js.map} +0 -0
- /package/dist/{kilo-GJNSBWVV.js.map → kilo-OU2ZLZKB.js.map} +0 -0
- /package/dist/{kilo-cli-2CCB3DBI.js.map → kilo-cli-NMWGYF4F.js.map} +0 -0
- /package/dist/{kimi-YRPCSB6N.js.map → kimi-Z7L2LEEI.js.map} +0 -0
- /package/dist/{leaderboard-SUSUDKHR.js.map → leaderboard-LF5SP6X2.js.map} +0 -0
- /package/dist/{mimo-code-V4FP5PUJ.js.map → mimo-code-G2CBZ4M6.js.map} +0 -0
- /package/dist/{mux-CMJSM42O.js.map → mux-JNM3F2NW.js.map} +0 -0
- /package/dist/{nemoclaw-VP56PGKC.js.map → nemoclaw-SHA4IUML.js.map} +0 -0
- /package/dist/{omp-OOFGD3GG.js.map → omp-OOVUNXME.js.map} +0 -0
- /package/dist/{openclaw-V73XHPXP.js.map → openclaw-BD56E5MV.js.map} +0 -0
- /package/dist/{opencode-MKLHSQRD.js.map → opencode-W2RK4M7G.js.map} +0 -0
- /package/dist/{package-KOAAVKHH.js.map → package-2EAIYSJ4.js.map} +0 -0
- /package/dist/{qwen-code-2XE2T6F4.js.map → qwen-code-TUJNHKNI.js.map} +0 -0
- /package/dist/{roo-code-YJOIKCCS.js.map → roo-code-L5F7S6QH.js.map} +0 -0
- /package/dist/{status-N5LCQQ3R.js.map → status-E5MCFZM6.js.map} +0 -0
- /package/dist/{statusline-442XOF7R.js.map → statusline-LIPF2KVP.js.map} +0 -0
- /package/dist/{telemetry-V4YQL2NU.js.map → telemetry-4OC56NTM.js.map} +0 -0
- /package/dist/{trae-QSV2JZFT.js.map → trae-Z7CQ2A2Q.js.map} +0 -0
- /package/dist/{uninstall-WGEKTCDZ.js.map → uninstall-2YYKN5DX.js.map} +0 -0
- /package/dist/{upgrade-IH7CKPTO.js.map → upgrade-55AFPJEF.js.map} +0 -0
- /package/dist/{usage-DI7XRCKM.js.map → usage-3PB3WZSL.js.map} +0 -0
- /package/dist/{usage-event-2FCU55AN.js.map → usage-event-KD5FW6W4.js.map} +0 -0
- /package/dist/{vscode-copilot-R23RTVST.js.map → vscode-copilot-LU5NC4ZS.js.map} +0 -0
- /package/dist/{warp-B72XSQ5G.js.map → warp-4PPG5LOM.js.map} +0 -0
- /package/dist/{windsurf-642VBMQ2.js.map → windsurf-3T3RVXKM.js.map} +0 -0
package/README.md
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
[](https://www.npmjs.com/package/@ken-jo/agent-connector)
|
|
10
10
|
[](LICENSE)
|
|
11
|
-

|
|
12
12
|

|
|
13
13
|

|
|
14
14
|

|
|
@@ -62,8 +62,8 @@ agent-connector is the middleware that does it for you:
|
|
|
62
62
|
>
|
|
63
63
|
> | Paradigm | Platforms |
|
|
64
64
|
> |---|---|
|
|
65
|
-
> | `json-stdio` (full hook dispatch) | Claude Code · Codex CLI · Cursor · VS Code Copilot · JetBrains Copilot · GitHub Copilot CLI · Gemini CLI · Qwen CLI · Kiro · Kimi CLI · Crush · Goose · Hermes · Droid (Factory) · Antigravity · Antigravity CLI · Continue · Amazon Q |
|
|
66
|
-
> | `mcp-only` (MCP registration only) | Warp · Roo Code · Cline · Trae · Zed · Codebuff · Mux · Pi · Windsurf |
|
|
65
|
+
> | `json-stdio` (full hook dispatch) | CodeBuddy · Claude Code · Codex CLI · Cursor · VS Code Copilot · JetBrains Copilot · GitHub Copilot CLI · Gemini CLI · Qwen CLI · Kiro · Kimi CLI · Crush · Goose · Hermes · Droid (Factory) · OpenHands · Antigravity · Antigravity CLI · Continue · Amazon Q · Grok CLI · Devin CLI |
|
|
66
|
+
> | `mcp-only` (MCP registration only) | Warp · Roo Code · Cline · Trae · Zed · Codebuff · Mux · Pi · Windsurf · Open Interpreter · Junie · Mistral Vibe |
|
|
67
67
|
> | `ts-plugin` (generated bridge module) | OpenCode · MiMoCode · Kilo CLI · Kilo · OMP · NemoClaw · OpenClaw · Amp |
|
|
68
68
|
>
|
|
69
69
|
> …plus the telemetry core. Adding a platform = **one registry entry + one
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
fail
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-7HUUINPB.js";
|
|
5
5
|
import {
|
|
6
6
|
runAction
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-BLTVZACS.js";
|
|
8
8
|
import "./chunk-OP4KBXUO.js";
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-D6ZJS4ND.js";
|
|
9
|
+
import "./chunk-LN76OGNR.js";
|
|
10
|
+
import "./chunk-ZMLVR4J7.js";
|
|
11
|
+
import "./chunk-LAIITCMW.js";
|
|
13
12
|
import "./chunk-KHO5WNTP.js";
|
|
14
|
-
import "./chunk-
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-
|
|
13
|
+
import "./chunk-4FWETID5.js";
|
|
14
|
+
import "./chunk-NWLRJNXM.js";
|
|
15
|
+
import "./chunk-G4CEELKO.js";
|
|
16
|
+
import "./chunk-25CPWJA7.js";
|
|
17
|
+
import "./chunk-56R2ER7K.js";
|
|
18
|
+
import "./chunk-HORHRHNG.js";
|
|
19
|
+
import "./chunk-YYNXIUR2.js";
|
|
20
|
+
import "./chunk-IXOQDZWC.js";
|
|
21
21
|
|
|
22
22
|
// src/cli/commands/action.ts
|
|
23
23
|
import { parseArgs } from "util";
|
|
@@ -52,4 +52,4 @@ async function run(argv) {
|
|
|
52
52
|
export {
|
|
53
53
|
run
|
|
54
54
|
};
|
|
55
|
-
//# sourceMappingURL=action-
|
|
55
|
+
//# sourceMappingURL=action-L44DXFHT.js.map
|
|
@@ -4,13 +4,13 @@ import {
|
|
|
4
4
|
} from "./chunk-BEFVJ2OE.js";
|
|
5
5
|
import {
|
|
6
6
|
BaseAdapter
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-VVFDU4IX.js";
|
|
8
8
|
import {
|
|
9
9
|
buildWrappedStdio,
|
|
10
10
|
isHomeBinHookCommand
|
|
11
|
-
} from "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
11
|
+
} from "./chunk-HORHRHNG.js";
|
|
12
|
+
import "./chunk-YYNXIUR2.js";
|
|
13
|
+
import "./chunk-IXOQDZWC.js";
|
|
14
14
|
|
|
15
15
|
// src/adapters/amazon-q/index.ts
|
|
16
16
|
import { existsSync, statSync } from "fs";
|
|
@@ -563,4 +563,4 @@ export {
|
|
|
563
563
|
adapter,
|
|
564
564
|
amazon_q_default as default
|
|
565
565
|
};
|
|
566
|
-
//# sourceMappingURL=amazon-q-
|
|
566
|
+
//# sourceMappingURL=amazon-q-B52EY2SV.js.map
|
|
@@ -8,12 +8,12 @@ import {
|
|
|
8
8
|
import {
|
|
9
9
|
BaseAdapter,
|
|
10
10
|
renderSkillMd
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-VVFDU4IX.js";
|
|
12
12
|
import {
|
|
13
13
|
buildWrappedStdio
|
|
14
|
-
} from "./chunk-
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-
|
|
14
|
+
} from "./chunk-HORHRHNG.js";
|
|
15
|
+
import "./chunk-YYNXIUR2.js";
|
|
16
|
+
import "./chunk-IXOQDZWC.js";
|
|
17
17
|
|
|
18
18
|
// src/adapters/amp/index.ts
|
|
19
19
|
import { existsSync } from "fs";
|
|
@@ -608,4 +608,4 @@ export {
|
|
|
608
608
|
adapter,
|
|
609
609
|
amp_default as default
|
|
610
610
|
};
|
|
611
|
-
//# sourceMappingURL=amp-
|
|
611
|
+
//# sourceMappingURL=amp-UXABVUKC.js.map
|
|
@@ -3,16 +3,16 @@ import {
|
|
|
3
3
|
AntigravityAdapter,
|
|
4
4
|
adapter,
|
|
5
5
|
antigravity_default
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-4HVQ7IUM.js";
|
|
7
7
|
import "./chunk-H53QZQJI.js";
|
|
8
8
|
import "./chunk-BEFVJ2OE.js";
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-VVFDU4IX.js";
|
|
10
|
+
import "./chunk-HORHRHNG.js";
|
|
11
|
+
import "./chunk-YYNXIUR2.js";
|
|
12
|
+
import "./chunk-IXOQDZWC.js";
|
|
13
13
|
export {
|
|
14
14
|
AntigravityAdapter,
|
|
15
15
|
adapter,
|
|
16
16
|
antigravity_default as default
|
|
17
17
|
};
|
|
18
|
-
//# sourceMappingURL=antigravity-
|
|
18
|
+
//# sourceMappingURL=antigravity-RZHN53VB.js.map
|
|
@@ -0,0 +1,436 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
AntigravityAdapter,
|
|
4
|
+
adapter
|
|
5
|
+
} from "./chunk-4HVQ7IUM.js";
|
|
6
|
+
import {
|
|
7
|
+
addLedgerOwner,
|
|
8
|
+
createLedgerEntry,
|
|
9
|
+
describeJsonValue,
|
|
10
|
+
dropLedgerEntry,
|
|
11
|
+
findLedgerEntry,
|
|
12
|
+
hashJsonValue,
|
|
13
|
+
jsonDeepEquals,
|
|
14
|
+
ledgerEntriesOwnedBy,
|
|
15
|
+
loadConfigPatchLedger,
|
|
16
|
+
removeLedgerOwner,
|
|
17
|
+
saveConfigPatchLedger
|
|
18
|
+
} from "./chunk-56R2ER7K.js";
|
|
19
|
+
import "./chunk-H53QZQJI.js";
|
|
20
|
+
import "./chunk-BEFVJ2OE.js";
|
|
21
|
+
import "./chunk-VVFDU4IX.js";
|
|
22
|
+
import {
|
|
23
|
+
buildHomeBinStatuslineCommand,
|
|
24
|
+
isHomeBinStatuslineCommand
|
|
25
|
+
} from "./chunk-HORHRHNG.js";
|
|
26
|
+
import "./chunk-YYNXIUR2.js";
|
|
27
|
+
import "./chunk-IXOQDZWC.js";
|
|
28
|
+
|
|
29
|
+
// src/adapters/antigravity-cli/index.ts
|
|
30
|
+
import { existsSync } from "fs";
|
|
31
|
+
import { homedir } from "os";
|
|
32
|
+
import { join } from "path";
|
|
33
|
+
var HOST = "antigravity-cli";
|
|
34
|
+
var STATUSLINE_KEY = "statusLine";
|
|
35
|
+
var AntigravityCliAdapter = class _AntigravityCliAdapter extends AntigravityAdapter {
|
|
36
|
+
id = HOST;
|
|
37
|
+
name = "Antigravity CLI";
|
|
38
|
+
/**
|
|
39
|
+
* Capabilities = the inherited IDE surface PLUS the CLI-only statusline (the
|
|
40
|
+
* `agy` custom status line, live-verified above). The IDE app does NOT advertise
|
|
41
|
+
* statusline (its payload is unverified), so this is the ONE capability that
|
|
42
|
+
* differs from the parent — everything else is spread from the IDE adapter's own
|
|
43
|
+
* capabilities so the two surfaces stay in lock-step (a parent field added later
|
|
44
|
+
* flows in automatically). `super.capabilities` is unusable here: the parent's
|
|
45
|
+
* `capabilities` is an instance FIELD (not on the prototype), so it resolves to
|
|
46
|
+
* undefined in a subclass field initializer — spread the IDE singleton instead.
|
|
47
|
+
*/
|
|
48
|
+
capabilities = {
|
|
49
|
+
...adapter.capabilities,
|
|
50
|
+
supportsStatusline: true
|
|
51
|
+
};
|
|
52
|
+
// ── Detection ────────────────────────────────────────────────────────────
|
|
53
|
+
/**
|
|
54
|
+
* Probe the CLI's runtime markers, DISTINCT from the IDE app even though the
|
|
55
|
+
* two share `~/.gemini/antigravity/`: the `agy` binary at ~/.local/bin/agy
|
|
56
|
+
* (the definitive CLI marker, CONFIRMED present) and the shared
|
|
57
|
+
* ~/.gemini/antigravity/ tree (or a user-scope mcp_config candidate / the
|
|
58
|
+
* project config). Reported before the IDE adapter in the registry so the
|
|
59
|
+
* more-specific CLI marker (the `agy` binary) wins host detection. Note: a
|
|
60
|
+
* machine with ONLY the IDE (no `agy` binary) will not match here, while one
|
|
61
|
+
* with the CLI matches on the binary regardless of the shared config dir.
|
|
62
|
+
*/
|
|
63
|
+
detectInstalled(projectDir) {
|
|
64
|
+
const home = homedir();
|
|
65
|
+
const userConfig = this.resolveUserConfigPath();
|
|
66
|
+
const agyBin = join(home, ".local", "bin", "agy");
|
|
67
|
+
const sharedDir = join(home, ".gemini", "antigravity");
|
|
68
|
+
const projectConfig = join(projectDir, ".agents", "mcp_config.json");
|
|
69
|
+
const cliMarker = existsSync(agyBin);
|
|
70
|
+
const userInstalled = cliMarker || existsSync(sharedDir) || this.userConfigCandidates().some((parts) => existsSync(join(home, ...parts)));
|
|
71
|
+
const projInstalled = existsSync(projectConfig);
|
|
72
|
+
const installed = userInstalled || projInstalled;
|
|
73
|
+
const scope = projInstalled && !userInstalled ? "project" : "user";
|
|
74
|
+
const configPath = scope === "project" ? projectConfig : userConfig;
|
|
75
|
+
return {
|
|
76
|
+
id: this.id,
|
|
77
|
+
name: this.name,
|
|
78
|
+
installed,
|
|
79
|
+
paradigm: this.paradigm,
|
|
80
|
+
capabilities: this.capabilities,
|
|
81
|
+
configPath,
|
|
82
|
+
scope,
|
|
83
|
+
reason: installed ? scope === "project" ? `found project Antigravity CLI config at ${projectConfig}` : `found Antigravity CLI (agy) at ${agyBin} / shared ${sharedDir}` : `no Antigravity CLI install at ${agyBin}, ${sharedDir}, or ${projectConfig}`,
|
|
84
|
+
// The `agy` binary is a high-confidence CLI marker; matching only the shared
|
|
85
|
+
// config dir is weaker (it could be a pure-IDE install).
|
|
86
|
+
confidence: cliMarker ? "high" : installed ? "medium" : "low"
|
|
87
|
+
};
|
|
88
|
+
}
|
|
89
|
+
/**
|
|
90
|
+
* MCP user-config path — LIVE-PROVEN for `agy` v1.0.5 (2026-06-04). The
|
|
91
|
+
* standalone CLI reads user MCP servers from `~/.gemini/config/mcp_config.json`
|
|
92
|
+
* (root key `mcpServers`), NOT the IDE's `~/.gemini/antigravity/mcp_config.json`:
|
|
93
|
+
* a real `agy -p` session spawned an MCP server ONLY when it was placed in
|
|
94
|
+
* `config/` (negative control: a server in `antigravity/` was ignored), and the
|
|
95
|
+
* binary carries the error string "failed to read mcp_config.json" + a literal
|
|
96
|
+
* "/.gemini/config" path. `agy mcp` is TUI-only (no headless add) and there is
|
|
97
|
+
* no `--mcp-config` flag. So the CLI must PREFER `config/` over the inherited
|
|
98
|
+
* `antigravity/` default; the IDE path stays as a prefer-existing fallback.
|
|
99
|
+
* (Skills/workflows/hooks dirs remain inherited; project scope
|
|
100
|
+
* `<proj>/.agents/mcp_config.json` is already correct and live-proven.)
|
|
101
|
+
*/
|
|
102
|
+
static CLI_USER_CONFIG_CANDIDATES = [
|
|
103
|
+
[".gemini", "config", "mcp_config.json"],
|
|
104
|
+
// CONFIRMED canonical for agy v1.0.5
|
|
105
|
+
[".gemini", "antigravity", "mcp_config.json"]
|
|
106
|
+
// legacy IDE layout (prefer-existing)
|
|
107
|
+
];
|
|
108
|
+
userConfigCandidates() {
|
|
109
|
+
return _AntigravityCliAdapter.CLI_USER_CONFIG_CANDIDATES;
|
|
110
|
+
}
|
|
111
|
+
// ── Statusline surface (the `agy` custom status line) ─────────────────────
|
|
112
|
+
// Wires settings.json `statusLine` = { enabled:true, command:<home-bin
|
|
113
|
+
// statusline cmd> } through the SAME refcounted ownership ledger as configPatch
|
|
114
|
+
// (the ledger primitives are surface-agnostic). antigravity-cli does NOT
|
|
115
|
+
// advertise supportsConfigPatch, so — like qwen-code — this adapter performs the
|
|
116
|
+
// set-if-absent write directly with the exported ledger primitives. Semantics
|
|
117
|
+
// are identical to claude-code/qwen-code: never clobber a `statusLine`
|
|
118
|
+
// agent-connector does not own (skip-warn), record prior state + owner
|
|
119
|
+
// (refcounted across connectors), reversible by uninstallStatusline
|
|
120
|
+
// (last-owner-verified delete).
|
|
121
|
+
//
|
|
122
|
+
// The home-bin command makes agy exec
|
|
123
|
+
// `<homeBin> statusline antigravity-cli --connector <id>` on every refresh,
|
|
124
|
+
// which re-imports the connector module and renders the line (runtime/
|
|
125
|
+
// statusline-entrypoint). The status line lives in the GLOBAL
|
|
126
|
+
// ~/.gemini/antigravity-cli/settings.json (agy has no project-scope statusLine),
|
|
127
|
+
// so this surface is user-scope regardless of the install scope. No telemetry
|
|
128
|
+
// in v1.
|
|
129
|
+
/**
|
|
130
|
+
* The `agy` settings.json that holds the statusLine config. LIVE-VERIFIED at
|
|
131
|
+
* ~/.gemini/antigravity-cli/settings.json (the CLI's own global home — distinct
|
|
132
|
+
* from the shared ~/.gemini/config/mcp_config.json the MCP surface writes). agy
|
|
133
|
+
* stores statusLine as a GLOBAL UI setting with no project-scope variant, so the
|
|
134
|
+
* path is scope-independent.
|
|
135
|
+
*/
|
|
136
|
+
statuslineSettingsPath() {
|
|
137
|
+
return join(homedir(), ".gemini", "antigravity-cli", "settings.json");
|
|
138
|
+
}
|
|
139
|
+
/** The statusLine config value agent-connector writes at `statusLine`. */
|
|
140
|
+
statuslineValue(ctx) {
|
|
141
|
+
const command = buildHomeBinStatuslineCommand(ctx.homeBinPath, HOST, ctx.connector.id);
|
|
142
|
+
return { enabled: true, command };
|
|
143
|
+
}
|
|
144
|
+
installStatusline(ctx) {
|
|
145
|
+
const { connector } = ctx;
|
|
146
|
+
if (connector.statusline == null) {
|
|
147
|
+
return [{ platform: this.id, action: "skip", detail: "connector declares no statusline" }];
|
|
148
|
+
}
|
|
149
|
+
if (connector.platforms[HOST]?.statusline === false) {
|
|
150
|
+
return [{ platform: this.id, action: "skip", detail: `statusline disabled for ${HOST}` }];
|
|
151
|
+
}
|
|
152
|
+
const filePath = this.statuslineSettingsPath();
|
|
153
|
+
const symlink = this.symlinkPathWarning(filePath);
|
|
154
|
+
if (symlink) return [symlink];
|
|
155
|
+
if (this.isPresentButUnparseable(filePath)) {
|
|
156
|
+
return [
|
|
157
|
+
{
|
|
158
|
+
platform: this.id,
|
|
159
|
+
action: "warn",
|
|
160
|
+
path: filePath,
|
|
161
|
+
detail: `existing ${filePath} is not parseable; statusline left unapplied (back it up / fix it, then re-run)`
|
|
162
|
+
}
|
|
163
|
+
];
|
|
164
|
+
}
|
|
165
|
+
const settings = this.readJson(filePath) ?? {};
|
|
166
|
+
if (typeof settings !== "object" || Array.isArray(settings)) {
|
|
167
|
+
return [
|
|
168
|
+
{
|
|
169
|
+
platform: this.id,
|
|
170
|
+
action: "warn",
|
|
171
|
+
path: filePath,
|
|
172
|
+
detail: `existing ${filePath} is not a JSON object; statusline left unapplied`
|
|
173
|
+
}
|
|
174
|
+
];
|
|
175
|
+
}
|
|
176
|
+
const ledger = loadConfigPatchLedger(ctx.dataRoot);
|
|
177
|
+
const desired = this.statuslineValue(ctx);
|
|
178
|
+
const leaf = settings[STATUSLINE_KEY];
|
|
179
|
+
const entry = findLedgerEntry(ledger, HOST, filePath, STATUSLINE_KEY);
|
|
180
|
+
const changes = [];
|
|
181
|
+
if (leaf === void 0) {
|
|
182
|
+
settings[STATUSLINE_KEY] = desired;
|
|
183
|
+
this.writeJson(filePath, settings, ctx.dryRun);
|
|
184
|
+
if (entry) {
|
|
185
|
+
entry.writtenValue = desired;
|
|
186
|
+
entry.writtenValueHash = hashJsonValue(desired);
|
|
187
|
+
addLedgerOwner(entry, connector.id, connector.version);
|
|
188
|
+
} else {
|
|
189
|
+
createLedgerEntry(ledger, {
|
|
190
|
+
platform: HOST,
|
|
191
|
+
file: filePath,
|
|
192
|
+
key: STATUSLINE_KEY,
|
|
193
|
+
value: desired,
|
|
194
|
+
connectorId: connector.id,
|
|
195
|
+
connectorVersion: connector.version
|
|
196
|
+
});
|
|
197
|
+
}
|
|
198
|
+
if (!ctx.dryRun) saveConfigPatchLedger(ctx.dataRoot, ledger);
|
|
199
|
+
changes.push({
|
|
200
|
+
platform: this.id,
|
|
201
|
+
action: "create",
|
|
202
|
+
path: filePath,
|
|
203
|
+
detail: `statusline ${STATUSLINE_KEY}: <absent> \u2192 ${describeJsonValue(desired)}`
|
|
204
|
+
});
|
|
205
|
+
return changes;
|
|
206
|
+
}
|
|
207
|
+
const leafValue = leaf;
|
|
208
|
+
if (!entry) {
|
|
209
|
+
return [
|
|
210
|
+
{
|
|
211
|
+
platform: this.id,
|
|
212
|
+
action: "warn",
|
|
213
|
+
path: filePath,
|
|
214
|
+
detail: `statusline ${STATUSLINE_KEY} skipped: already set to ${describeJsonValue(leafValue)} (not created by agent-connector) \u2014 left untouched`
|
|
215
|
+
}
|
|
216
|
+
];
|
|
217
|
+
}
|
|
218
|
+
if (!jsonDeepEquals(leafValue, entry.writtenValue)) {
|
|
219
|
+
return [
|
|
220
|
+
{
|
|
221
|
+
platform: this.id,
|
|
222
|
+
action: "warn",
|
|
223
|
+
path: filePath,
|
|
224
|
+
detail: `statusline ${STATUSLINE_KEY}: value changed since install (current ${describeJsonValue(leafValue)}, wrote ${describeJsonValue(entry.writtenValue)}); leaving in place`
|
|
225
|
+
}
|
|
226
|
+
];
|
|
227
|
+
}
|
|
228
|
+
if (jsonDeepEquals(desired, leafValue)) {
|
|
229
|
+
const owners = entry.owners.map((o) => o.connectorId);
|
|
230
|
+
if (addLedgerOwner(entry, connector.id, connector.version)) {
|
|
231
|
+
if (!ctx.dryRun) saveConfigPatchLedger(ctx.dataRoot, ledger);
|
|
232
|
+
return [
|
|
233
|
+
{
|
|
234
|
+
platform: this.id,
|
|
235
|
+
action: "skip",
|
|
236
|
+
path: filePath,
|
|
237
|
+
detail: `statusline ${STATUSLINE_KEY} already installed; registered as co-owner (co-owned with ${owners.join(", ")})`
|
|
238
|
+
}
|
|
239
|
+
];
|
|
240
|
+
}
|
|
241
|
+
return [
|
|
242
|
+
{
|
|
243
|
+
platform: this.id,
|
|
244
|
+
action: "skip",
|
|
245
|
+
path: filePath,
|
|
246
|
+
detail: `statusline ${STATUSLINE_KEY} already installed`
|
|
247
|
+
}
|
|
248
|
+
];
|
|
249
|
+
}
|
|
250
|
+
return [
|
|
251
|
+
{
|
|
252
|
+
platform: this.id,
|
|
253
|
+
action: "warn",
|
|
254
|
+
path: filePath,
|
|
255
|
+
detail: `statusline ${STATUSLINE_KEY} skipped: already owned by ${entry.owners.map((o) => o.connectorId).join(", ")} with a different value \u2014 left untouched`
|
|
256
|
+
}
|
|
257
|
+
];
|
|
258
|
+
}
|
|
259
|
+
uninstallStatusline(ctx) {
|
|
260
|
+
const ledger = loadConfigPatchLedger(ctx.dataRoot);
|
|
261
|
+
const owned = ledgerEntriesOwnedBy(ledger, HOST, ctx.connector.id).filter(
|
|
262
|
+
(e) => e.key === STATUSLINE_KEY
|
|
263
|
+
);
|
|
264
|
+
if (owned.length === 0) {
|
|
265
|
+
return [
|
|
266
|
+
{
|
|
267
|
+
platform: this.id,
|
|
268
|
+
action: "skip",
|
|
269
|
+
detail: "statusline: no ownership recorded; left untouched"
|
|
270
|
+
}
|
|
271
|
+
];
|
|
272
|
+
}
|
|
273
|
+
const changes = [];
|
|
274
|
+
let ledgerMutated = false;
|
|
275
|
+
const byFile = /* @__PURE__ */ new Map();
|
|
276
|
+
for (const entry of owned) {
|
|
277
|
+
const bucket = byFile.get(entry.file) ?? [];
|
|
278
|
+
bucket.push(entry);
|
|
279
|
+
byFile.set(entry.file, bucket);
|
|
280
|
+
}
|
|
281
|
+
for (const [filePath, entries] of byFile) {
|
|
282
|
+
const symlink = this.symlinkPathWarning(filePath);
|
|
283
|
+
if (symlink) {
|
|
284
|
+
changes.push(symlink);
|
|
285
|
+
continue;
|
|
286
|
+
}
|
|
287
|
+
const unparseable = this.isPresentButUnparseable(filePath);
|
|
288
|
+
const settings = unparseable ? null : this.readJson(filePath);
|
|
289
|
+
let fileMutated = false;
|
|
290
|
+
for (const entry of entries) {
|
|
291
|
+
const { lastOwner } = removeLedgerOwner(entry, ctx.connector.id);
|
|
292
|
+
ledgerMutated = true;
|
|
293
|
+
if (!lastOwner) {
|
|
294
|
+
changes.push({
|
|
295
|
+
platform: this.id,
|
|
296
|
+
action: "skip",
|
|
297
|
+
path: filePath,
|
|
298
|
+
detail: `statusline ${entry.key} retained: still owned by ${entry.owners.map((o) => o.connectorId).join(", ")}`
|
|
299
|
+
});
|
|
300
|
+
continue;
|
|
301
|
+
}
|
|
302
|
+
dropLedgerEntry(ledger, entry);
|
|
303
|
+
if (unparseable) {
|
|
304
|
+
changes.push({
|
|
305
|
+
platform: this.id,
|
|
306
|
+
action: "warn",
|
|
307
|
+
path: filePath,
|
|
308
|
+
detail: `statusline ${entry.key}: ${filePath} is not parseable; key left in place (ownership released)`
|
|
309
|
+
});
|
|
310
|
+
continue;
|
|
311
|
+
}
|
|
312
|
+
if (!settings || typeof settings !== "object" || Array.isArray(settings)) {
|
|
313
|
+
changes.push({
|
|
314
|
+
platform: this.id,
|
|
315
|
+
action: "skip",
|
|
316
|
+
path: filePath,
|
|
317
|
+
detail: `statusline ${entry.key} already absent (no settings file); ownership record dropped`
|
|
318
|
+
});
|
|
319
|
+
continue;
|
|
320
|
+
}
|
|
321
|
+
const leaf = settings[entry.key];
|
|
322
|
+
if (leaf === void 0) {
|
|
323
|
+
changes.push({
|
|
324
|
+
platform: this.id,
|
|
325
|
+
action: "skip",
|
|
326
|
+
path: filePath,
|
|
327
|
+
detail: `statusline ${entry.key} already absent; ownership record dropped`
|
|
328
|
+
});
|
|
329
|
+
continue;
|
|
330
|
+
}
|
|
331
|
+
if (entry.prior?.present !== false || !jsonDeepEquals(leaf, entry.writtenValue)) {
|
|
332
|
+
changes.push({
|
|
333
|
+
platform: this.id,
|
|
334
|
+
action: "warn",
|
|
335
|
+
path: filePath,
|
|
336
|
+
detail: `statusline ${entry.key}: value changed since install (current ${describeJsonValue(leaf)}, wrote ${describeJsonValue(entry.writtenValue)}); left in place`
|
|
337
|
+
});
|
|
338
|
+
continue;
|
|
339
|
+
}
|
|
340
|
+
delete settings[entry.key];
|
|
341
|
+
fileMutated = true;
|
|
342
|
+
changes.push({
|
|
343
|
+
platform: this.id,
|
|
344
|
+
action: "remove",
|
|
345
|
+
path: filePath,
|
|
346
|
+
detail: `statusline ${entry.key} removed (was ${describeJsonValue(entry.writtenValue)})`
|
|
347
|
+
});
|
|
348
|
+
}
|
|
349
|
+
if (fileMutated && settings) this.writeJson(filePath, settings, ctx.dryRun);
|
|
350
|
+
}
|
|
351
|
+
if (ledgerMutated && !ctx.dryRun) saveConfigPatchLedger(ctx.dataRoot, ledger);
|
|
352
|
+
return changes;
|
|
353
|
+
}
|
|
354
|
+
/**
|
|
355
|
+
* Parse the `agy` statusLine stdin JSON into the normalized
|
|
356
|
+
* {@link StatuslineContext}. agy pipes a JSON object on stdin
|
|
357
|
+
* (model/context_window/workspace/…); fields the payload omits stay undefined.
|
|
358
|
+
* `raw` keeps the verbatim payload (incl. version/agent_state/vcs/plan_tier/
|
|
359
|
+
* quota/email/terminal_width). agy has no cost analog, so `ctx.cost` is left
|
|
360
|
+
* undefined. LIVE-CAPTURED against agy v1.0.10 (see header / AgyStatuslineInput).
|
|
361
|
+
*/
|
|
362
|
+
parseStatusInput(raw) {
|
|
363
|
+
const input = raw ?? {};
|
|
364
|
+
const ctx = {
|
|
365
|
+
host: HOST,
|
|
366
|
+
capabilities: this.capabilities,
|
|
367
|
+
raw
|
|
368
|
+
};
|
|
369
|
+
const sessionId = typeof input.conversation_id === "string" && input.conversation_id !== "" ? input.conversation_id : typeof input.session_id === "string" && input.session_id !== "" ? input.session_id : void 0;
|
|
370
|
+
if (sessionId !== void 0) ctx.sessionId = sessionId;
|
|
371
|
+
const cwd = typeof input.cwd === "string" ? input.cwd : typeof input.workspace?.current_dir === "string" ? input.workspace.current_dir : void 0;
|
|
372
|
+
if (cwd !== void 0) ctx.cwd = cwd;
|
|
373
|
+
if (typeof input.transcript_path === "string") ctx.transcriptPath = input.transcript_path;
|
|
374
|
+
const model = {};
|
|
375
|
+
if (typeof input.model?.id === "string") model.id = input.model.id;
|
|
376
|
+
if (typeof input.model?.display_name === "string") model.displayName = input.model.display_name;
|
|
377
|
+
if (model.id !== void 0 || model.displayName !== void 0) ctx.model = model;
|
|
378
|
+
const cw = input.context_window;
|
|
379
|
+
if (cw) {
|
|
380
|
+
const context = {};
|
|
381
|
+
if (typeof cw.context_window_size === "number") context.maxTokens = cw.context_window_size;
|
|
382
|
+
if (typeof cw.total_input_tokens === "number" || typeof cw.total_output_tokens === "number") {
|
|
383
|
+
context.usedTokens = (cw.total_input_tokens ?? 0) + (cw.total_output_tokens ?? 0);
|
|
384
|
+
}
|
|
385
|
+
if (typeof cw.used_percentage === "number") context.percent = cw.used_percentage;
|
|
386
|
+
if (context.usedTokens !== void 0 || context.maxTokens !== void 0 || context.percent !== void 0) {
|
|
387
|
+
ctx.context = context;
|
|
388
|
+
}
|
|
389
|
+
}
|
|
390
|
+
return ctx;
|
|
391
|
+
}
|
|
392
|
+
/** Format the rendered status line into agy's native reply: stdout = line, exit 0. */
|
|
393
|
+
formatStatusOutput(rendered) {
|
|
394
|
+
return { exitCode: 0, stdout: rendered };
|
|
395
|
+
}
|
|
396
|
+
// ── Diagnostics: add the statusline check on top of the inherited IDE checks ─
|
|
397
|
+
getHealthChecks(ctx) {
|
|
398
|
+
const checks = [...super.getHealthChecks(ctx)];
|
|
399
|
+
const settingsPath = this.statuslineSettingsPath();
|
|
400
|
+
const connectorId = ctx.connector.id;
|
|
401
|
+
const homeBin = ctx.homeBinPath;
|
|
402
|
+
const statuslineLedgerOwned = ledgerEntriesOwnedBy(
|
|
403
|
+
loadConfigPatchLedger(ctx.dataRoot),
|
|
404
|
+
HOST,
|
|
405
|
+
connectorId
|
|
406
|
+
).some((e) => e.key === STATUSLINE_KEY);
|
|
407
|
+
if ((ctx.connector.statusline != null || statuslineLedgerOwned) && ctx.connector.platforms[HOST]?.statusline !== false) {
|
|
408
|
+
checks.push({
|
|
409
|
+
name: `${this.name}: statusline wired`,
|
|
410
|
+
check: () => {
|
|
411
|
+
const settings = this.readJson(settingsPath);
|
|
412
|
+
const command = settings?.statusLine?.command;
|
|
413
|
+
if (command === void 0) {
|
|
414
|
+
return { status: "FAIL", detail: `statusLine not set in ${settingsPath}` };
|
|
415
|
+
}
|
|
416
|
+
if (typeof command === "string" && isHomeBinStatuslineCommand(command, homeBin, connectorId)) {
|
|
417
|
+
return { status: "OK", detail: "statusLine command present" };
|
|
418
|
+
}
|
|
419
|
+
return {
|
|
420
|
+
status: "FAIL",
|
|
421
|
+
detail: `statusLine in ${settingsPath} is not agent-connector's (left untouched)`
|
|
422
|
+
};
|
|
423
|
+
}
|
|
424
|
+
});
|
|
425
|
+
}
|
|
426
|
+
return checks;
|
|
427
|
+
}
|
|
428
|
+
};
|
|
429
|
+
var adapter2 = new AntigravityCliAdapter();
|
|
430
|
+
var antigravity_cli_default = adapter2;
|
|
431
|
+
export {
|
|
432
|
+
AntigravityCliAdapter,
|
|
433
|
+
adapter2 as adapter,
|
|
434
|
+
antigravity_cli_default as default
|
|
435
|
+
};
|
|
436
|
+
//# sourceMappingURL=antigravity-cli-JO6GUTV7.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/adapters/antigravity-cli/index.ts"],"sourcesContent":["/**\n * adapters/antigravity-cli — Google Antigravity CLI (`agy`) platform adapter.\n *\n * Antigravity ships in two distinct runtimes that share the Gemini-family\n * `~/.gemini` tree and ALL of the same native formats (the JSON `mcp_config.json`\n * shape, the `hooks.json` lifecycle-hook shape, markdown Workflows, and Agent\n * Skills `SKILL.md`): the IDE/desktop app (the parent `AntigravityAdapter`,\n * id \"antigravity\") and this standalone CLI binary `agy` (id \"antigravity-cli\").\n *\n * This adapter is a thin fork of the IDE adapter. It REUSES every render / hook /\n * parse / surface path from {@link AntigravityAdapter} unchanged — the only\n * differences are identity and detection:\n *\n * - id = \"antigravity-cli\", name = \"Antigravity CLI\". Identity flows into the\n * universal hook command (`<homeBin> hook antigravity-cli <event> …`) and the\n * `hostPlatform` stamp, so a CLI-installed hook dispatches back to THIS\n * adapter at runtime — the reason the parent's install/parse logic was made\n * to read `this.id` rather than a fixed host constant.\n * - Detection probes the `agy` binary at ~/.local/bin/agy and/or the SHARED\n * ~/.gemini/antigravity/ presence (distinct runtime markers from the IDE).\n *\n * CONFIRMED-BY-INSTALL (2026-06-03, docs/research/antigravity-paths-confirmed.md):\n * the `agy` CLI v1.0.0 has NO separate config dir — `~/.gemini/antigravity-cli/`,\n * `~/.config/antigravity*`, and `~/.agy` are ALL ABSENT. `agy` SHARES the IDE's\n * `~/.gemini/antigravity/` tree (mcp_config.json, hooks.json, workflows, skills).\n * So the user-scope config resolution here is IDENTICAL to the IDE adapter (the\n * inherited USER_CONFIG_CANDIDATES) — installing both the IDE and CLI connectors\n * therefore writes the SAME files and is idempotent (observed as skip), which is\n * expected and correct. `agy`'s own extension surface is the `agy plugin` system\n * (install/uninstall/list/enable/disable) — future work would deploy as an agy\n * plugin; for now the MCP/workflows/skills surfaces ride the shared IDE files.\n *\n * LIVE-TEST RESOLUTION (2026-06-04, real `agy` v1.0.5 login + spawn): the prior\n * \"shares the IDE's ~/.gemini/antigravity/ file\" claim was WRONG for the CLI. The\n * standalone `agy` reads user MCP from **~/.gemini/config/mcp_config.json**\n * (root key `mcpServers`; project scope <proj>/.agents/mcp_config.json) — PROVEN:\n * a live `agy -p` session spawned an MCP server placed in `config/` and completed\n * a real initialize+tools/list+tools/call handshake; a negative control in\n * `antigravity/` was ignored. The binary carries \"failed to read mcp_config.json\"\n * + a literal \"/.gemini/config\" path; there is NO `--mcp-config` flag and `agy\n * mcp` is TUI-only. So this adapter now OVERRIDES userConfigCandidates to prefer\n * `~/.gemini/config/mcp_config.json` (canonical) over the inherited IDE\n * `antigravity/` default (kept as a prefer-existing fallback). Telemetry-wrap is\n * compatible: agy spawns command+args verbatim, so the home-bin serve wrapper is\n * spawned as written — i.e. a real agy session now emits a per-MCP telemetry row.\n * (agy also keeps its own home ~/.gemini/antigravity-cli/ for auth/state, but MCP\n * config lives in the shared ~/.gemini/config/.)\n *\n * Project scope is IDENTICAL to the IDE adapter (`<proj>/.agents/…`), as is every\n * hook/command/skill render and the runtime parse/format — all inherited.\n *\n * The user-scope config paths shared with the IDE (hooks.json + the global skills\n * dir) remain MEDIUM-CONFIDENCE / PATH-PROBED in the parent (not present on the\n * observed install) and surfaced by the doctor; user-scope mcp_config + workflows\n * are CONFIRMED at ~/.gemini/antigravity/.\n *\n * STATUSLINE SURFACE (LIVE-VERIFIED 2026-06-21, agy v1.0.10): the `agy` CLI ships\n * a first-party custom status line — `/statusline <command>` configures a shell\n * command that agy execs on each refresh, piping a JSON status payload on stdin.\n * The config is persisted in the GLOBAL `~/.gemini/antigravity-cli/settings.json`\n * under the top-level `statusLine` key, value shape `{ enabled: true, command }`\n * — NOT claude-code's `{ type:\"command\", command }` and NOT qwen-code's nested\n * `ui.statusLine`. This was confirmed by a real headless `agy -p` turn with the\n * statusLine command pointed at a stdin-logging script: the captured payload is\n * { cwd, session_id, conversation_id, transcript_path,\n * model:{ id, display_name },\n * workspace:{ current_dir, project_dir },\n * version,\n * context_window:{ total_input_tokens, total_output_tokens,\n * context_window_size, used_percentage,\n * remaining_percentage,\n * current_usage:{ input_tokens, output_tokens, … } },\n * exceeds_200k_tokens, product, quota, agent_state, vcs, sandbox,\n * plan_tier, email, terminal_width }\n * Only the antigravity-cli FORK wires this (the IDE app's payload is not verified),\n * so the CLI adapter overrides `capabilities` to add `supportsStatusline: true`\n * and the statusline parse/format/install/uninstall here — every other path stays\n * inherited from {@link AntigravityAdapter}.\n */\n\nimport { existsSync } from \"node:fs\";\nimport { homedir } from \"node:os\";\nimport { join } from \"node:path\";\n\nimport { AntigravityAdapter, adapter as antigravityIdeAdapter } from \"../antigravity/index.js\";\nimport type { Adapter, HookReply, InstallContext } from \"../spi.js\";\nimport type {\n ChangeRecord,\n DetectedPlatform,\n HealthCheck,\n JsonValue,\n PlatformCapabilities,\n PlatformId,\n StatuslineContext,\n} from \"../../core/types.js\";\nimport {\n buildHomeBinStatuslineCommand,\n isHomeBinStatuslineCommand,\n} from \"../../core/spawn.js\";\nimport {\n type ConfigPatchLedgerEntry,\n addLedgerOwner,\n createLedgerEntry,\n describeJsonValue,\n dropLedgerEntry,\n findLedgerEntry,\n hashJsonValue,\n jsonDeepEquals,\n ledgerEntriesOwnedBy,\n loadConfigPatchLedger,\n removeLedgerOwner,\n saveConfigPatchLedger,\n} from \"../../core/config-patch-ledger.js\";\n\nconst HOST: PlatformId = \"antigravity-cli\";\n\n/**\n * settings.json key the statusline surface owns on `agy`. The agy CLI stores its\n * custom status line under the TOP-LEVEL `statusLine` key (a single segment —\n * unlike qwen-code's nested `ui.statusLine`). LIVE-VERIFIED against agy v1.0.10\n * (binary StatusLineConfig JSON tags `statusLine`/`command`/`enabled`; a real turn\n * accepted and fired this shape). We own the `statusLine` leaf via the SAME\n * refcounted ownership ledger as configPatch — never clobbering a `statusLine` a\n * user (or another tool) already set.\n */\nconst STATUSLINE_KEY = \"statusLine\";\n\n/**\n * The `agy` statusLine custom-command stdin payload (the documented status-line\n * input agy pipes on stdin, read once). Every field optional — a refresh only\n * carries what the host knows. LIVE-CAPTURED (agy v1.0.10, 2026-06-21). Unmodeled\n * fields (version, agent_state, vcs, plan_tier, quota, product, email,\n * terminal_width) stay in StatuslineContext.raw.\n *\n * NOTE the divergence from qwen-code: agy's `context_window.current_usage` is an\n * OBJECT (`{ input_tokens, output_tokens, … }`), NOT a number — so used tokens are\n * derived from the top-level `total_input_tokens + total_output_tokens`, and the\n * percent from `used_percentage`.\n */\ninterface AgyStatuslineInput {\n cwd?: string;\n session_id?: string;\n conversation_id?: string;\n transcript_path?: string;\n version?: string;\n model?: { id?: string; display_name?: string };\n workspace?: { current_dir?: string; project_dir?: string };\n context_window?: {\n total_input_tokens?: number;\n total_output_tokens?: number;\n context_window_size?: number;\n used_percentage?: number;\n remaining_percentage?: number;\n current_usage?: {\n input_tokens?: number;\n output_tokens?: number;\n cache_creation_input_tokens?: number;\n cache_read_input_tokens?: number;\n };\n };\n}\n\nexport class AntigravityCliAdapter extends AntigravityAdapter implements Adapter {\n override readonly id: PlatformId = HOST;\n override readonly name = \"Antigravity CLI\";\n\n /**\n * Capabilities = the inherited IDE surface PLUS the CLI-only statusline (the\n * `agy` custom status line, live-verified above). The IDE app does NOT advertise\n * statusline (its payload is unverified), so this is the ONE capability that\n * differs from the parent — everything else is spread from the IDE adapter's own\n * capabilities so the two surfaces stay in lock-step (a parent field added later\n * flows in automatically). `super.capabilities` is unusable here: the parent's\n * `capabilities` is an instance FIELD (not on the prototype), so it resolves to\n * undefined in a subclass field initializer — spread the IDE singleton instead.\n */\n override readonly capabilities: PlatformCapabilities = {\n ...antigravityIdeAdapter.capabilities,\n supportsStatusline: true,\n };\n\n // ── Detection ────────────────────────────────────────────────────────────\n\n /**\n * Probe the CLI's runtime markers, DISTINCT from the IDE app even though the\n * two share `~/.gemini/antigravity/`: the `agy` binary at ~/.local/bin/agy\n * (the definitive CLI marker, CONFIRMED present) and the shared\n * ~/.gemini/antigravity/ tree (or a user-scope mcp_config candidate / the\n * project config). Reported before the IDE adapter in the registry so the\n * more-specific CLI marker (the `agy` binary) wins host detection. Note: a\n * machine with ONLY the IDE (no `agy` binary) will not match here, while one\n * with the CLI matches on the binary regardless of the shared config dir.\n */\n override detectInstalled(projectDir: string): DetectedPlatform {\n const home = homedir();\n const userConfig = this.resolveUserConfigPath();\n const agyBin = join(home, \".local\", \"bin\", \"agy\");\n const sharedDir = join(home, \".gemini\", \"antigravity\");\n const projectConfig = join(projectDir, \".agents\", \"mcp_config.json\");\n\n // The `agy` binary is the definitive CLI marker. The shared antigravity dir\n // and the user-scope mcp_config candidates are secondary signals (they also\n // match a pure-IDE install, so the binary is what truly distinguishes the CLI).\n const cliMarker = existsSync(agyBin);\n const userInstalled =\n cliMarker ||\n existsSync(sharedDir) ||\n this.userConfigCandidates().some((parts) => existsSync(join(home, ...parts)));\n const projInstalled = existsSync(projectConfig);\n const installed = userInstalled || projInstalled;\n\n // Report the scope/path that actually matched, so a project-only install\n // isn't misreported as a (non-existent) user install.\n const scope = projInstalled && !userInstalled ? \"project\" : \"user\";\n const configPath = scope === \"project\" ? projectConfig : userConfig;\n\n return {\n id: this.id,\n name: this.name,\n installed,\n paradigm: this.paradigm,\n capabilities: this.capabilities,\n configPath,\n scope,\n reason: installed\n ? scope === \"project\"\n ? `found project Antigravity CLI config at ${projectConfig}`\n : `found Antigravity CLI (agy) at ${agyBin} / shared ${sharedDir}`\n : `no Antigravity CLI install at ${agyBin}, ${sharedDir}, or ${projectConfig}`,\n // The `agy` binary is a high-confidence CLI marker; matching only the shared\n // config dir is weaker (it could be a pure-IDE install).\n confidence: cliMarker ? \"high\" : installed ? \"medium\" : \"low\",\n };\n }\n\n /**\n * MCP user-config path — LIVE-PROVEN for `agy` v1.0.5 (2026-06-04). The\n * standalone CLI reads user MCP servers from `~/.gemini/config/mcp_config.json`\n * (root key `mcpServers`), NOT the IDE's `~/.gemini/antigravity/mcp_config.json`:\n * a real `agy -p` session spawned an MCP server ONLY when it was placed in\n * `config/` (negative control: a server in `antigravity/` was ignored), and the\n * binary carries the error string \"failed to read mcp_config.json\" + a literal\n * \"/.gemini/config\" path. `agy mcp` is TUI-only (no headless add) and there is\n * no `--mcp-config` flag. So the CLI must PREFER `config/` over the inherited\n * `antigravity/` default; the IDE path stays as a prefer-existing fallback.\n * (Skills/workflows/hooks dirs remain inherited; project scope\n * `<proj>/.agents/mcp_config.json` is already correct and live-proven.)\n */\n private static readonly CLI_USER_CONFIG_CANDIDATES = [\n [\".gemini\", \"config\", \"mcp_config.json\"], // CONFIRMED canonical for agy v1.0.5\n [\".gemini\", \"antigravity\", \"mcp_config.json\"], // legacy IDE layout (prefer-existing)\n ] as const;\n\n protected override userConfigCandidates(): ReadonlyArray<readonly string[]> {\n return AntigravityCliAdapter.CLI_USER_CONFIG_CANDIDATES;\n }\n\n // ── Statusline surface (the `agy` custom status line) ─────────────────────\n // Wires settings.json `statusLine` = { enabled:true, command:<home-bin\n // statusline cmd> } through the SAME refcounted ownership ledger as configPatch\n // (the ledger primitives are surface-agnostic). antigravity-cli does NOT\n // advertise supportsConfigPatch, so — like qwen-code — this adapter performs the\n // set-if-absent write directly with the exported ledger primitives. Semantics\n // are identical to claude-code/qwen-code: never clobber a `statusLine`\n // agent-connector does not own (skip-warn), record prior state + owner\n // (refcounted across connectors), reversible by uninstallStatusline\n // (last-owner-verified delete).\n //\n // The home-bin command makes agy exec\n // `<homeBin> statusline antigravity-cli --connector <id>` on every refresh,\n // which re-imports the connector module and renders the line (runtime/\n // statusline-entrypoint). The status line lives in the GLOBAL\n // ~/.gemini/antigravity-cli/settings.json (agy has no project-scope statusLine),\n // so this surface is user-scope regardless of the install scope. No telemetry\n // in v1.\n\n /**\n * The `agy` settings.json that holds the statusLine config. LIVE-VERIFIED at\n * ~/.gemini/antigravity-cli/settings.json (the CLI's own global home — distinct\n * from the shared ~/.gemini/config/mcp_config.json the MCP surface writes). agy\n * stores statusLine as a GLOBAL UI setting with no project-scope variant, so the\n * path is scope-independent.\n */\n private statuslineSettingsPath(): string {\n return join(homedir(), \".gemini\", \"antigravity-cli\", \"settings.json\");\n }\n\n /** The statusLine config value agent-connector writes at `statusLine`. */\n private statuslineValue(ctx: InstallContext): JsonValue {\n const command = buildHomeBinStatuslineCommand(ctx.homeBinPath, HOST, ctx.connector.id);\n return { enabled: true, command };\n }\n\n override installStatusline(ctx: InstallContext): ChangeRecord[] {\n const { connector } = ctx;\n if (connector.statusline == null) {\n return [{ platform: this.id, action: \"skip\", detail: \"connector declares no statusline\" }];\n }\n if (connector.platforms[HOST]?.statusline === false) {\n return [{ platform: this.id, action: \"skip\", detail: `statusline disabled for ${HOST}` }];\n }\n\n const filePath = this.statuslineSettingsPath();\n const symlink = this.symlinkPathWarning(filePath);\n if (symlink) return [symlink];\n\n // OVERWRITE GUARD (upsertServerInJson precedent): never round-trip a\n // present-but-unparseable settings file into `{}`.\n if (this.isPresentButUnparseable(filePath)) {\n return [\n {\n platform: this.id,\n action: \"warn\",\n path: filePath,\n detail: `existing ${filePath} is not parseable; statusline left unapplied (back it up / fix it, then re-run)`,\n },\n ];\n }\n const settings = this.readJson<Record<string, unknown>>(filePath) ?? {};\n if (typeof settings !== \"object\" || Array.isArray(settings)) {\n return [\n {\n platform: this.id,\n action: \"warn\",\n path: filePath,\n detail: `existing ${filePath} is not a JSON object; statusline left unapplied`,\n },\n ];\n }\n\n const ledger = loadConfigPatchLedger(ctx.dataRoot);\n const desired = this.statuslineValue(ctx);\n const leaf = settings[STATUSLINE_KEY];\n const entry = findLedgerEntry(ledger, HOST, filePath, STATUSLINE_KEY);\n const changes: ChangeRecord[] = [];\n\n if (leaf === undefined) {\n // SET-IF-ABSENT: the one write path.\n settings[STATUSLINE_KEY] = desired;\n this.writeJson(filePath, settings, ctx.dryRun);\n if (entry) {\n // Stale ledger row (key deleted out from under us): re-assert the value,\n // keep existing owners (they still rely on the key), record what we wrote.\n entry.writtenValue = desired;\n entry.writtenValueHash = hashJsonValue(desired);\n addLedgerOwner(entry, connector.id, connector.version);\n } else {\n createLedgerEntry(ledger, {\n platform: HOST,\n file: filePath,\n key: STATUSLINE_KEY,\n value: desired,\n connectorId: connector.id,\n connectorVersion: connector.version,\n });\n }\n if (!ctx.dryRun) saveConfigPatchLedger(ctx.dataRoot, ledger);\n changes.push({\n platform: this.id,\n action: \"create\",\n path: filePath,\n detail: `statusline ${STATUSLINE_KEY}: <absent> → ${describeJsonValue(desired)}`,\n });\n return changes;\n }\n\n // Key PRESENT — never overwrite; the only question is ownership/refcount.\n const leafValue = leaf as JsonValue;\n if (!entry) {\n // User- (or other-tool-) owned. No ownership is taken even when the values\n // happen to match — uninstall must never delete a key we did not create.\n return [\n {\n platform: this.id,\n action: \"warn\",\n path: filePath,\n detail:\n `statusline ${STATUSLINE_KEY} skipped: already set to ${describeJsonValue(leafValue)} ` +\n `(not created by agent-connector) — left untouched`,\n },\n ];\n }\n\n if (!jsonDeepEquals(leafValue, entry.writtenValue)) {\n // DRIFT: the user edited the value after we wrote it. Never revert.\n return [\n {\n platform: this.id,\n action: \"warn\",\n path: filePath,\n detail:\n `statusline ${STATUSLINE_KEY}: value changed since install ` +\n `(current ${describeJsonValue(leafValue)}, wrote ${describeJsonValue(entry.writtenValue)}); ` +\n `leaving in place`,\n },\n ];\n }\n\n if (jsonDeepEquals(desired, leafValue)) {\n // Same value we own: register as co-owner (refcount++) or idempotent skip.\n const owners = entry.owners.map((o) => o.connectorId);\n if (addLedgerOwner(entry, connector.id, connector.version)) {\n if (!ctx.dryRun) saveConfigPatchLedger(ctx.dataRoot, ledger);\n return [\n {\n platform: this.id,\n action: \"skip\",\n path: filePath,\n detail: `statusline ${STATUSLINE_KEY} already installed; registered as co-owner (co-owned with ${owners.join(\", \")})`,\n },\n ];\n }\n return [\n {\n platform: this.id,\n action: \"skip\",\n path: filePath,\n detail: `statusline ${STATUSLINE_KEY} already installed`,\n },\n ];\n }\n\n // FIRST-WRITER-WINS: another connector owns the key with a different value.\n return [\n {\n platform: this.id,\n action: \"warn\",\n path: filePath,\n detail:\n `statusline ${STATUSLINE_KEY} skipped: already owned by ${entry.owners\n .map((o) => o.connectorId)\n .join(\", \")} with a different value — left untouched`,\n },\n ];\n }\n\n override uninstallStatusline(ctx: InstallContext): ChangeRecord[] {\n const ledger = loadConfigPatchLedger(ctx.dataRoot);\n // Release ONLY the statusLine ledger row this connector owns (keyed off the\n // ledger, not the declaration, so an id-only synthetic uninstall still reclaims\n // it). Last-owner-verified delete: remove the key ONLY when last-owner ∧\n // value-unchanged ∧ prior-absent (else skip-warn + leave the key).\n const owned = ledgerEntriesOwnedBy(ledger, HOST, ctx.connector.id).filter(\n (e) => e.key === STATUSLINE_KEY,\n );\n if (owned.length === 0) {\n return [\n {\n platform: this.id,\n action: \"skip\",\n detail: \"statusline: no ownership recorded; left untouched\",\n },\n ];\n }\n\n const changes: ChangeRecord[] = [];\n let ledgerMutated = false;\n\n // Group by file (one global settings.json in practice, but stay robust to a\n // scope drift between install and uninstall).\n const byFile = new Map<string, ConfigPatchLedgerEntry[]>();\n for (const entry of owned) {\n const bucket = byFile.get(entry.file) ?? [];\n bucket.push(entry);\n byFile.set(entry.file, bucket);\n }\n\n for (const [filePath, entries] of byFile) {\n const symlink = this.symlinkPathWarning(filePath);\n if (symlink) {\n changes.push(symlink);\n continue;\n }\n\n const unparseable = this.isPresentButUnparseable(filePath);\n const settings = unparseable ? null : this.readJson<Record<string, unknown>>(filePath);\n let fileMutated = false;\n\n for (const entry of entries) {\n const { lastOwner } = removeLedgerOwner(entry, ctx.connector.id);\n ledgerMutated = true;\n\n if (!lastOwner) {\n // Shared-flag case: A uninstalls, B still relies on the key.\n changes.push({\n platform: this.id,\n action: \"skip\",\n path: filePath,\n detail: `statusline ${entry.key} retained: still owned by ${entry.owners\n .map((o) => o.connectorId)\n .join(\", \")}`,\n });\n continue;\n }\n\n // Last owner out → the ledger row is dropped on every branch below; the\n // KEY is removed only on the fully-verified branch.\n dropLedgerEntry(ledger, entry);\n\n if (unparseable) {\n changes.push({\n platform: this.id,\n action: \"warn\",\n path: filePath,\n detail: `statusline ${entry.key}: ${filePath} is not parseable; key left in place (ownership released)`,\n });\n continue;\n }\n if (!settings || typeof settings !== \"object\" || Array.isArray(settings)) {\n changes.push({\n platform: this.id,\n action: \"skip\",\n path: filePath,\n detail: `statusline ${entry.key} already absent (no settings file); ownership record dropped`,\n });\n continue;\n }\n const leaf = settings[entry.key];\n if (leaf === undefined) {\n changes.push({\n platform: this.id,\n action: \"skip\",\n path: filePath,\n detail: `statusline ${entry.key} already absent; ownership record dropped`,\n });\n continue;\n }\n if (entry.prior?.present !== false || !jsonDeepEquals(leaf as JsonValue, entry.writtenValue)) {\n // User edited the value after install (or the row predates the\n // set-if-absent guarantee): deleting would clobber them. Leave it.\n changes.push({\n platform: this.id,\n action: \"warn\",\n path: filePath,\n detail:\n `statusline ${entry.key}: value changed since install ` +\n `(current ${describeJsonValue(leaf as JsonValue)}, wrote ${describeJsonValue(entry.writtenValue)}); ` +\n `left in place`,\n });\n continue;\n }\n\n // VERIFIED: last owner + current === writtenValue + prior absent.\n delete settings[entry.key];\n fileMutated = true;\n changes.push({\n platform: this.id,\n action: \"remove\",\n path: filePath,\n detail: `statusline ${entry.key} removed (was ${describeJsonValue(entry.writtenValue)})`,\n });\n }\n\n if (fileMutated && settings) this.writeJson(filePath, settings, ctx.dryRun);\n }\n\n if (ledgerMutated && !ctx.dryRun) saveConfigPatchLedger(ctx.dataRoot, ledger);\n return changes;\n }\n\n /**\n * Parse the `agy` statusLine stdin JSON into the normalized\n * {@link StatuslineContext}. agy pipes a JSON object on stdin\n * (model/context_window/workspace/…); fields the payload omits stay undefined.\n * `raw` keeps the verbatim payload (incl. version/agent_state/vcs/plan_tier/\n * quota/email/terminal_width). agy has no cost analog, so `ctx.cost` is left\n * undefined. LIVE-CAPTURED against agy v1.0.10 (see header / AgyStatuslineInput).\n */\n parseStatusInput(raw: unknown): StatuslineContext {\n const input = (raw ?? {}) as AgyStatuslineInput;\n\n const ctx: StatuslineContext = {\n host: HOST,\n capabilities: this.capabilities,\n raw,\n };\n // Stable session id: prefer conversation_id (the active agent conversation),\n // fall back to session_id (the capture showed them equal).\n const sessionId =\n typeof input.conversation_id === \"string\" && input.conversation_id !== \"\"\n ? input.conversation_id\n : typeof input.session_id === \"string\" && input.session_id !== \"\"\n ? input.session_id\n : undefined;\n if (sessionId !== undefined) ctx.sessionId = sessionId;\n // cwd: prefer the top-level cwd, else the workspace.current_dir.\n const cwd =\n typeof input.cwd === \"string\"\n ? input.cwd\n : typeof input.workspace?.current_dir === \"string\"\n ? input.workspace.current_dir\n : undefined;\n if (cwd !== undefined) ctx.cwd = cwd;\n if (typeof input.transcript_path === \"string\") ctx.transcriptPath = input.transcript_path;\n\n const model: { id?: string; displayName?: string } = {};\n if (typeof input.model?.id === \"string\") model.id = input.model.id;\n if (typeof input.model?.display_name === \"string\") model.displayName = input.model.display_name;\n if (model.id !== undefined || model.displayName !== undefined) ctx.model = model;\n\n const cw = input.context_window;\n if (cw) {\n const context: { usedTokens?: number; maxTokens?: number; percent?: number } = {};\n if (typeof cw.context_window_size === \"number\") context.maxTokens = cw.context_window_size;\n // agy's current_usage is an OBJECT (not a number like qwen) — used tokens are\n // the documented top-level total_input_tokens + total_output_tokens sum.\n if (\n typeof cw.total_input_tokens === \"number\" ||\n typeof cw.total_output_tokens === \"number\"\n ) {\n context.usedTokens = (cw.total_input_tokens ?? 0) + (cw.total_output_tokens ?? 0);\n }\n if (typeof cw.used_percentage === \"number\") context.percent = cw.used_percentage;\n if (\n context.usedTokens !== undefined ||\n context.maxTokens !== undefined ||\n context.percent !== undefined\n ) {\n ctx.context = context;\n }\n }\n // ctx.cost stays undefined: agy's status payload has no cost analog.\n return ctx;\n }\n\n /** Format the rendered status line into agy's native reply: stdout = line, exit 0. */\n formatStatusOutput(rendered: string): HookReply {\n return { exitCode: 0, stdout: rendered };\n }\n\n // ── Diagnostics: add the statusline check on top of the inherited IDE checks ─\n\n override getHealthChecks(ctx: InstallContext): readonly HealthCheck[] {\n const checks = [...super.getHealthChecks(ctx)];\n\n // Statusline check: assert it when the connector declares a statusline AND it\n // is not disabled for this host, OR when the ownership ledger holds a\n // statusLine row this connector owns (the REGISTERED-connector path:\n // connectorFromMeta can't re-expose the render fn, so statusline comes back\n // undefined — but the ledger row proves the surface was wired). Mirrors\n // claude-code/qwen-code's \"statusline wired\" check.\n const settingsPath = this.statuslineSettingsPath();\n const connectorId = ctx.connector.id;\n const homeBin = ctx.homeBinPath;\n const statuslineLedgerOwned = ledgerEntriesOwnedBy(\n loadConfigPatchLedger(ctx.dataRoot),\n HOST,\n connectorId,\n ).some((e) => e.key === STATUSLINE_KEY);\n if (\n (ctx.connector.statusline != null || statuslineLedgerOwned) &&\n ctx.connector.platforms[HOST]?.statusline !== false\n ) {\n checks.push({\n name: `${this.name}: statusline wired`,\n check: () => {\n const settings = this.readJson<{ statusLine?: { command?: unknown } }>(settingsPath);\n const command = settings?.statusLine?.command;\n if (command === undefined) {\n return { status: \"FAIL\", detail: `statusLine not set in ${settingsPath}` };\n }\n if (\n typeof command === \"string\" &&\n isHomeBinStatuslineCommand(command, homeBin, connectorId)\n ) {\n return { status: \"OK\", detail: \"statusLine command present\" };\n }\n // Present but not ours — a non-AC statusLine we must never clobber.\n return {\n status: \"FAIL\",\n detail: `statusLine in ${settingsPath} is not agent-connector's (left untouched)`,\n };\n },\n });\n }\n return checks;\n }\n}\n\nexport const adapter = new AntigravityCliAdapter();\nexport default adapter;\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgFA,SAAS,kBAAkB;AAC3B,SAAS,eAAe;AACxB,SAAS,YAAY;AAgCrB,IAAM,OAAmB;AAWzB,IAAM,iBAAiB;AAqChB,IAAM,wBAAN,MAAM,+BAA8B,mBAAsC;AAAA,EAC7D,KAAiB;AAAA,EACjB,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAYP,eAAqC;AAAA,IACrD,GAAG,QAAsB;AAAA,IACzB,oBAAoB;AAAA,EACtB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAcS,gBAAgB,YAAsC;AAC7D,UAAM,OAAO,QAAQ;AACrB,UAAM,aAAa,KAAK,sBAAsB;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