pushary 1.9.63 → 1.9.65

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.
Files changed (129) hide show
  1. package/CHANGELOG.md +20 -1
  2. package/README.md +1 -1
  3. package/dist/{api-UHUUAONF.js → api-32B3XLJR.js} +10 -11
  4. package/dist/bin/pushary-bell-hook.js +27 -30
  5. package/dist/bin/pushary-bell.js +12 -13
  6. package/dist/bin/pushary-claude.js +28 -31
  7. package/dist/bin/pushary-clean.js +68 -43
  8. package/dist/bin/pushary-codex-bridge.js +22 -24
  9. package/dist/bin/pushary-codex-hook.js +34 -37
  10. package/dist/bin/pushary-codex-session.js +8 -8
  11. package/dist/bin/pushary-codex.js +13 -15
  12. package/dist/bin/pushary-connect.js +26 -29
  13. package/dist/bin/pushary-cowork.js +5 -5
  14. package/dist/bin/pushary-daemon.js +39 -42
  15. package/dist/bin/pushary-disconnect.js +62 -43
  16. package/dist/bin/pushary-doctor.js +109 -44
  17. package/dist/bin/pushary-elicitation-hook.js +27 -30
  18. package/dist/bin/pushary-gemini-bridge.js +16 -18
  19. package/dist/bin/pushary-gemini-hook.js +29 -32
  20. package/dist/bin/pushary-hook.js +31 -34
  21. package/dist/bin/pushary-login.js +19 -20
  22. package/dist/bin/pushary-logout.js +26 -29
  23. package/dist/bin/pushary-mcp.js +11 -12
  24. package/dist/bin/pushary-mode.js +14 -15
  25. package/dist/bin/pushary-notification-hook.js +26 -29
  26. package/dist/bin/pushary-opencode-hook.js +28 -31
  27. package/dist/bin/pushary-permission-denied-hook.js +31 -34
  28. package/dist/bin/pushary-permission-hook.js +30 -33
  29. package/dist/bin/pushary-post-hook.js +26 -29
  30. package/dist/bin/pushary-prompt-hook.js +26 -29
  31. package/dist/bin/pushary-session-end-hook.js +28 -31
  32. package/dist/bin/pushary-session-start-hook.js +35 -38
  33. package/dist/bin/pushary-setup.js +129 -74
  34. package/dist/bin/pushary-stats.js +5 -5
  35. package/dist/bin/pushary-status.js +31 -34
  36. package/dist/bin/pushary-stop-hook.js +26 -29
  37. package/dist/bin/pushary-stopfailure-hook.js +26 -29
  38. package/dist/bin/pushary-suggestions.js +14 -15
  39. package/dist/bin/pushary-transcript-register.js +18 -21
  40. package/dist/bin/pushary-transcripts.js +17 -18
  41. package/dist/bin/pushary-upgrade.js +40 -44
  42. package/dist/bin/pushary-wait.js +14 -15
  43. package/dist/bin/pushary.js +7 -8
  44. package/dist/{chunk-V5W3CK7F.js → chunk-2VADJ6JH.js} +2 -2
  45. package/dist/{chunk-3GVV7XVT.js → chunk-2Z7I7DHT.js} +1 -1
  46. package/dist/{chunk-7GRQGXF4.js → chunk-3KXBRSL3.js} +1 -1
  47. package/dist/{chunk-P6RF4RQN.js → chunk-3LF7T3NW.js} +6 -6
  48. package/dist/{chunk-PXAOEFJZ.js → chunk-3UNAPXED.js} +14 -16
  49. package/dist/{chunk-TMGJAFSD.js → chunk-4LUWNBGD.js} +3 -3
  50. package/dist/{chunk-CLABCSZC.js → chunk-6CZX6YOE.js} +5 -5
  51. package/dist/{chunk-VFJSVPNL.js → chunk-7ILQX47W.js} +3 -3
  52. package/dist/{chunk-4WFAP6QN.js → chunk-ADXHPGBZ.js} +9 -11
  53. package/dist/{chunk-75ODMNOM.js → chunk-AN7C3CHH.js} +1 -1
  54. package/dist/{chunk-BQFL2ECS.js → chunk-ANP3DIST.js} +3 -57
  55. package/dist/chunk-ATPJGHUP.js +1201 -0
  56. package/dist/{chunk-6Z2VR3BA.js → chunk-BAGBCSXA.js} +1 -1
  57. package/dist/{chunk-WUOOZE5S.js → chunk-BEQ3MEE3.js} +2 -2
  58. package/dist/{chunk-ELAK46NR.js → chunk-BKCI53W6.js} +4 -4
  59. package/dist/{chunk-HAIXS4OX.js → chunk-CSKABVSH.js} +3 -3
  60. package/dist/{chunk-GNUARBRZ.js → chunk-CU2PXLZ6.js} +4 -4
  61. package/dist/{chunk-FVERRWDP.js → chunk-CZ65D6Q5.js} +2 -2
  62. package/dist/{chunk-PJ34FOIV.js → chunk-DM24VZOI.js} +5 -5
  63. package/dist/{chunk-TBKHQWIH.js → chunk-DTVHZDYM.js} +5 -5
  64. package/dist/{chunk-PIQ4HHA2.js → chunk-DXMUJTYF.js} +4 -6
  65. package/dist/{chunk-IOH2T3CB.js → chunk-ED2SWTPC.js} +4 -4
  66. package/dist/{chunk-FAF5AW3P.js → chunk-EEVE7H5Z.js} +4 -4
  67. package/dist/{chunk-EHHTQURL.js → chunk-F56GTJFG.js} +5 -5
  68. package/dist/{chunk-GZS72NCF.js → chunk-FFSIYBBU.js} +4 -4
  69. package/dist/{chunk-L5CDGXPO.js → chunk-FWS2KLV2.js} +4 -4
  70. package/dist/{chunk-T3GHXR6N.js → chunk-GA257T2E.js} +5 -5
  71. package/dist/{chunk-SKUSGWFK.js → chunk-GTBWWCCM.js} +6 -6
  72. package/dist/{chunk-YK6GR4GU.js → chunk-HDGB6SQ4.js} +2 -2
  73. package/dist/{chunk-OY6Z4IKB.js → chunk-HIYLAC3C.js} +3 -3
  74. package/dist/{chunk-RAJ3QEIL.js → chunk-HVOQUPSO.js} +1 -1
  75. package/dist/{chunk-KUCL7ETL.js → chunk-I2UBF2SS.js} +1 -1
  76. package/dist/{chunk-VHZAJ6IB.js → chunk-ICFHMJTW.js} +3 -3
  77. package/dist/{chunk-HZ72EMJE.js → chunk-ITYKN2K3.js} +2 -2
  78. package/dist/{chunk-XBTWG2VL.js → chunk-IZVEBBDH.js} +5 -5
  79. package/dist/{chunk-VN7XH6TU.js → chunk-JCWHOB36.js} +2 -2
  80. package/dist/{chunk-5JK3DQGZ.js → chunk-JFKMPLNF.js} +2 -2
  81. package/dist/{chunk-FEAGK25K.js → chunk-LMC5UPL7.js} +1 -1
  82. package/dist/{chunk-7NCLUA65.js → chunk-MNKIR2ZB.js} +11 -0
  83. package/dist/{chunk-SARPHHTT.js → chunk-NOH3EJFH.js} +1 -1
  84. package/dist/{chunk-OP5IBEV7.js → chunk-NUEPJ5W6.js} +2 -2
  85. package/dist/{chunk-OU3BYBJ3.js → chunk-OA6EADFT.js} +3 -3
  86. package/dist/{chunk-LGZ545TA.js → chunk-ONBL2GCU.js} +12 -6
  87. package/dist/{chunk-LTT54NOU.js → chunk-P5HZEGT7.js} +65 -8
  88. package/dist/{chunk-YMZOM6BD.js → chunk-PP7FC3Y7.js} +10 -10
  89. package/dist/{chunk-T6XQNOZV.js → chunk-Q2BD4IBX.js} +12 -12
  90. package/dist/{chunk-DMNLFWGY.js → chunk-QNZ6G3LY.js} +210 -151
  91. package/dist/{chunk-BCVCUDFI.js → chunk-QSW3HAKI.js} +1 -1
  92. package/dist/{chunk-HOIO66DU.js → chunk-R4FL5JHK.js} +4 -4
  93. package/dist/{chunk-VUFHYMSP.js → chunk-RABLE5R6.js} +1 -1
  94. package/dist/{chunk-2MZ6ROWZ.js → chunk-RRHHWYPX.js} +6 -6
  95. package/dist/{chunk-5LOP4AVD.js → chunk-SCMEVDAR.js} +128 -26
  96. package/dist/{chunk-XE5N352V.js → chunk-SROWUG5W.js} +1 -1
  97. package/dist/{chunk-QW3FRUFB.js → chunk-SZBMTOUZ.js} +1 -1
  98. package/dist/{chunk-V7N5NOZV.js → chunk-TJUJAK5L.js} +1 -1
  99. package/dist/{chunk-OJEIS5L2.js → chunk-TK4JU2F7.js} +1 -1
  100. package/dist/{chunk-VDBXSUXP.js → chunk-U2P2LQ5B.js} +7 -7
  101. package/dist/{chunk-AB3VAQ25.js → chunk-UHS5MMAI.js} +3 -3
  102. package/dist/{chunk-OW6VBXXI.js → chunk-UM2X7HL6.js} +63 -36
  103. package/dist/{chunk-KL76XWZ7.js → chunk-UMTMFDL2.js} +1 -1
  104. package/dist/{chunk-MRCVYYPW.js → chunk-VHKK3US3.js} +3 -3
  105. package/dist/{chunk-S2Z6VWHH.js → chunk-W5L2ZLHE.js} +6 -7
  106. package/dist/{chunk-EQ26IKZM.js → chunk-WOHP7EL6.js} +7 -6
  107. package/dist/{chunk-3QLFB2EY.js → chunk-WY6YAMZW.js} +37 -214
  108. package/dist/{chunk-XO3KAH7K.js → chunk-XJIIU36L.js} +1 -1
  109. package/dist/{chunk-QC2W42DE.js → chunk-XZCJC3QO.js} +12 -12
  110. package/dist/{chunk-BUQU3OPX.js → chunk-Y64JGYTB.js} +1 -1
  111. package/dist/{chunk-KLZZI5TU.js → chunk-Z3M627TQ.js} +1 -1
  112. package/dist/{codex-app-cards-switch-LXMAIOFB.js → codex-app-cards-switch-HK4RMOBI.js} +11 -12
  113. package/dist/{codex-desktop-launch-VE5RLFUU.js → codex-desktop-launch-OCO6N7SA.js} +1 -1
  114. package/dist/{codex-session-launch-XZZWXCPK.js → codex-session-launch-ETZQTVFS.js} +19 -21
  115. package/dist/{config-PPX25AV5.js → config-YY54G3CC.js} +3 -3
  116. package/dist/{global-upgrade-NRMHNLNU.js → global-upgrade-5DN5G3ZQ.js} +10 -12
  117. package/dist/{identity-ZFQR7JNW.js → identity-EGL6HAWG.js} +4 -5
  118. package/dist/{live-capabilities-SJRYRKNB.js → live-capabilities-WU3FYJJG.js} +5 -7
  119. package/dist/{paths-7VTVOQXJ.js → paths-ZG6KDM6Y.js} +7 -3
  120. package/dist/reapply-AQLNCCTE.js +63 -0
  121. package/dist/src/index.js +20 -23
  122. package/dist/{upgrade-lock-VAYJZVTB.js → upgrade-lock-BIRXIKHJ.js} +4 -5
  123. package/dist/{usage-C4DIYUR6.js → usage-43C2DHDU.js} +3 -3
  124. package/package.json +1 -1
  125. package/dist/chunk-6ICPEJY5.js +0 -20
  126. package/dist/chunk-MK4USZYQ.js +0 -615
  127. package/dist/chunk-QENTGE75.js +0 -86
  128. package/dist/chunk-VC3HFFMQ.js +0 -41
  129. package/dist/reapply-WOANOIRZ.js +0 -64
@@ -2,18 +2,18 @@
2
2
  import {
3
3
  declinedAgentsFile,
4
4
  recordDeclinedAgent
5
- } from "../chunk-XBTWG2VL.js";
5
+ } from "../chunk-IZVEBBDH.js";
6
6
  import {
7
7
  isCursorPluginLeftover,
8
8
  isPusharyCursorPluginManifest,
9
9
  releaseSoleGate
10
- } from "../chunk-GNUARBRZ.js";
10
+ } from "../chunk-CU2PXLZ6.js";
11
11
  import {
12
12
  planFxRemoval,
13
- removeInstructionBlock
14
- } from "../chunk-DMNLFWGY.js";
15
- import "../chunk-S2Z6VWHH.js";
16
- import "../chunk-WUOOZE5S.js";
13
+ removeClineServer
14
+ } from "../chunk-QNZ6G3LY.js";
15
+ import "../chunk-W5L2ZLHE.js";
16
+ import "../chunk-BEQ3MEE3.js";
17
17
  import {
18
18
  OPENCODE_PLUGIN_SIBLING,
19
19
  OPENCODE_PLUGIN_SIBLING_CONTENTS,
@@ -25,60 +25,52 @@ import {
25
25
  openCodePluginDir,
26
26
  openCodePluginFile,
27
27
  removeOpenCodeMcpServer
28
- } from "../chunk-LTT54NOU.js";
28
+ } from "../chunk-P5HZEGT7.js";
29
29
  import {
30
30
  exitOnHelpFlag
31
- } from "../chunk-75ODMNOM.js";
31
+ } from "../chunk-AN7C3CHH.js";
32
32
  import {
33
33
  compatibleConfigFile,
34
34
  compatibleDocuments,
35
35
  compatibleInstructionsFile,
36
36
  compatibleMcpFile,
37
37
  compatiblePermissionRuleFile,
38
- isClaudeMcpSnapshot,
39
38
  isEmptiedPusharyOwnedDocument,
40
- removeClaudeMcpServers,
41
39
  removeCompatibleHooks,
42
- removeCompatibleMcpServer,
43
- removePusharySettings,
44
- removePusharyToolPermissions,
45
- restoreClaudeMcpServer
46
- } from "../chunk-3QLFB2EY.js";
47
- import "../chunk-SKUSGWFK.js";
40
+ removeCompatibleMcpServer
41
+ } from "../chunk-WY6YAMZW.js";
42
+ import "../chunk-GTBWWCCM.js";
48
43
  import {
49
44
  removeGeminiSettings
50
- } from "../chunk-BQFL2ECS.js";
51
- import "../chunk-XE5N352V.js";
52
- import "../chunk-KLZZI5TU.js";
45
+ } from "../chunk-ANP3DIST.js";
46
+ import "../chunk-SROWUG5W.js";
47
+ import "../chunk-Z3M627TQ.js";
53
48
  import {
54
49
  parseFlags
55
50
  } from "../chunk-NMUI3ZWG.js";
56
- import "../chunk-6ICPEJY5.js";
57
- import "../chunk-IOH2T3CB.js";
58
- import "../chunk-PXAOEFJZ.js";
59
- import "../chunk-VC3HFFMQ.js";
60
- import "../chunk-7GRQGXF4.js";
61
- import "../chunk-TBKHQWIH.js";
51
+ import "../chunk-ED2SWTPC.js";
52
+ import "../chunk-3UNAPXED.js";
53
+ import "../chunk-3KXBRSL3.js";
54
+ import "../chunk-DTVHZDYM.js";
62
55
  import "../chunk-POFBE6ZY.js";
63
- import "../chunk-ELAK46NR.js";
64
- import "../chunk-AB3VAQ25.js";
65
- import "../chunk-VFJSVPNL.js";
66
- import "../chunk-L5CDGXPO.js";
56
+ import "../chunk-BKCI53W6.js";
57
+ import "../chunk-UHS5MMAI.js";
58
+ import "../chunk-7ILQX47W.js";
59
+ import "../chunk-FWS2KLV2.js";
67
60
  import {
68
61
  UsageError
69
62
  } from "../chunk-PPY5N2E6.js";
70
63
  import {
71
64
  EXIT
72
65
  } from "../chunk-KZERVKTD.js";
73
- import "../chunk-V5W3CK7F.js";
74
- import {
75
- readFileOrMissing
76
- } from "../chunk-QENTGE75.js";
66
+ import "../chunk-2VADJ6JH.js";
77
67
  import {
78
68
  claudeJson,
79
69
  claudeMcpReceipt,
80
70
  claudeSettings,
81
71
  claudeSettingsLocal,
72
+ clineMcpSettings,
73
+ clineRules,
82
74
  codexAgentsMd,
83
75
  codexConfigToml,
84
76
  codexHookPositions,
@@ -93,21 +85,29 @@ import {
93
85
  fxSettings,
94
86
  geminiMd,
95
87
  geminiSettings,
88
+ isClaudeMcpSnapshot,
89
+ removeClaudeMcpServers,
96
90
  removeCodexHooks,
97
- removeCodexSettings
98
- } from "../chunk-MK4USZYQ.js";
99
- import "../chunk-5LOP4AVD.js";
100
- import "../chunk-BUQU3OPX.js";
91
+ removeCodexSettings,
92
+ removeInstructionBlock,
93
+ removePusharySettings,
94
+ removePusharyToolPermissions,
95
+ restoreClaudeMcpServer
96
+ } from "../chunk-ATPJGHUP.js";
97
+ import {
98
+ readFileOrMissing
99
+ } from "../chunk-SCMEVDAR.js";
100
+ import "../chunk-Y64JGYTB.js";
101
101
  import {
102
102
  isInvocationOf
103
- } from "../chunk-6Z2VR3BA.js";
103
+ } from "../chunk-BAGBCSXA.js";
104
104
  import "../chunk-QTOLNRET.js";
105
105
  import {
106
106
  DISCONNECTABLE_AGENTS,
107
107
  DISCONNECT_AGENT_IDS,
108
108
  hookCompatibleProfileBySource,
109
109
  normalizeAgentId
110
- } from "../chunk-7NCLUA65.js";
110
+ } from "../chunk-MNKIR2ZB.js";
111
111
  import "../chunk-MLKGABMK.js";
112
112
 
113
113
  // bin/pushary-disconnect.ts
@@ -378,11 +378,21 @@ var disconnectFx = (io) => {
378
378
  if (io.removeInstructionBlock(fxAgentsMd())) changed.push(fxAgentsMd());
379
379
  return { changed, kept };
380
380
  };
381
+ var disconnectCline = (io) => {
382
+ const changed = [];
383
+ const failed = [];
384
+ const removal = removeClineServer(clineMcpSettings());
385
+ if (removal.kind === "write") changed.push(removal.path);
386
+ if (removal.kind === "kept" || removal.kind === "failed") failed.push(`Cline MCP: ${removal.detail}`);
387
+ if (io.removeInstructionBlock(clineRules())) changed.push(clineRules());
388
+ return { changed, failed };
389
+ };
381
390
 
382
391
  // bin/pushary-disconnect.ts
383
392
  exitOnHelpFlag("disconnect");
384
393
  var MAC_APP_LEAVES_IT_OFF = (agent) => `The Pushary Mac app will leave ${agent} off until you connect it again, from the app or with pushary setup.`;
385
394
  var MAC_APP_MAY_RESTORE_IT = (agent, file) => `Could not write ${file}, so a running Pushary Mac app may connect ${agent} again. Turn it off in the app's Settings too.`;
395
+ var AGENTS_THE_MAC_APP_NEVER_CONNECTS = /* @__PURE__ */ new Set(["cline"]);
386
396
  var rest = process.argv.slice(2);
387
397
  var typed;
388
398
  try {
@@ -395,16 +405,22 @@ try {
395
405
  process.exit(EXIT.USAGE);
396
406
  }
397
407
  var requested = typed === void 0 ? null : normalizeAgentId(typed, DISCONNECT_AGENT_IDS);
398
- var printResult = (agent, changed, kept) => {
399
- if (changed.length === 0) console.log(`${agent} was not connected.`);
400
- else {
408
+ var printResult = (agent, changed, kept, failed = []) => {
409
+ if (changed.length > 0) {
401
410
  console.log(`Disconnected ${agent}:`);
402
411
  for (const path of changed) console.log(` ${path}`);
412
+ } else if (failed.length === 0) {
413
+ console.log(`${agent} was not connected.`);
403
414
  }
404
415
  if (kept.length > 0) {
405
416
  console.log("Left as it is:");
406
417
  for (const line of kept) console.log(` ${line}`);
407
418
  }
419
+ if (failed.length > 0) {
420
+ console.error(`Could not finish disconnecting ${agent}:`);
421
+ for (const line of failed) console.error(` ${line}`);
422
+ process.exitCode = EXIT.FAILED;
423
+ }
408
424
  };
409
425
  if (requested === null) {
410
426
  if (typed !== void 0) console.error(`Unknown agent: ${typed}`);
@@ -431,6 +447,9 @@ if (isDisconnectableAgent(requested)) {
431
447
  removeInstructionBlock
432
448
  });
433
449
  printResult(requested, result.changed, result.kept);
450
+ } else if (requested === "cline") {
451
+ const result = disconnectCline({ removeInstructionBlock });
452
+ printResult(requested, result.changed, [], result.failed);
434
453
  } else {
435
454
  const result = disconnectFx({
436
455
  write: (path, contents) => writeFileSync(path, contents, "utf-8"),
@@ -439,6 +458,6 @@ if (isDisconnectableAgent(requested)) {
439
458
  });
440
459
  printResult(requested, result.changed, result.kept);
441
460
  }
442
- if (decline !== "unchanged" && macAppBridgeAvailable()) {
461
+ if (decline !== "unchanged" && !AGENTS_THE_MAC_APP_NEVER_CONNECTS.has(requested) && macAppBridgeAvailable()) {
443
462
  console.log(decline === "changed" ? MAC_APP_LEAVES_IT_OFF(requested) : MAC_APP_MAY_RESTORE_IT(requested, declinedAgentsFile()));
444
463
  }
@@ -3,20 +3,20 @@ import {
3
3
  readServiceExecPath,
4
4
  readSetupFailure,
5
5
  versionManagerOf
6
- } from "../chunk-HAIXS4OX.js";
6
+ } from "../chunk-CSKABVSH.js";
7
7
  import {
8
8
  CODEX_HOOK_REMEDY
9
- } from "../chunk-VN7XH6TU.js";
9
+ } from "../chunk-JCWHOB36.js";
10
10
  import {
11
11
  describeWaitLadder
12
12
  } from "../chunk-CVWG2N3Y.js";
13
13
  import {
14
14
  writeJsonError,
15
15
  writeStdoutFully
16
- } from "../chunk-3GVV7XVT.js";
16
+ } from "../chunk-2Z7I7DHT.js";
17
17
  import {
18
18
  fetchChannels
19
- } from "../chunk-FAF5AW3P.js";
19
+ } from "../chunk-EEVE7H5Z.js";
20
20
  import "../chunk-3EGEA4KH.js";
21
21
  import {
22
22
  describeAnswerTestPrompt,
@@ -26,15 +26,15 @@ import {
26
26
  reachVerdict,
27
27
  roundTripEvidence,
28
28
  verifyRoundTrip
29
- } from "../chunk-VHZAJ6IB.js";
29
+ } from "../chunk-ICFHMJTW.js";
30
30
  import {
31
31
  readMachineReadiness,
32
32
  readManagedControlEvidence
33
- } from "../chunk-EHHTQURL.js";
33
+ } from "../chunk-F56GTJFG.js";
34
34
  import {
35
35
  assessCodexHookTrust,
36
36
  readCodexTrustForPusharyHooks
37
- } from "../chunk-YK6GR4GU.js";
37
+ } from "../chunk-HDGB6SQ4.js";
38
38
  import {
39
39
  HERMES_PIP_PACKAGE,
40
40
  HERMES_PLUGIN_NAME,
@@ -48,55 +48,57 @@ import {
48
48
  resolveHermesPython,
49
49
  shortenHome,
50
50
  vscodeSettingsTargets
51
- } from "../chunk-LGZ545TA.js";
51
+ } from "../chunk-ONBL2GCU.js";
52
52
  import {
53
53
  CONNECTED_THROUGH_MAC_APP,
54
54
  readMacAppConnectionWhenKeyless
55
- } from "../chunk-VDBXSUXP.js";
55
+ } from "../chunk-U2P2LQ5B.js";
56
56
  import "../chunk-QCGNGEGE.js";
57
57
  import {
58
58
  SIGNED_OUT_ON_MAC_MESSAGE,
59
59
  activeKeyVerdictOf,
60
60
  describeSignedOutKey,
61
61
  readSignedOutDiagnosis
62
- } from "../chunk-HZ72EMJE.js";
62
+ } from "../chunk-ITYKN2K3.js";
63
63
  import {
64
64
  FX_PROFILE_REFUSALS,
65
65
  FX_PUSHARY_TOOLS_RULE,
66
66
  FX_QUESTION_TOOL,
67
- hasInstructionBlock,
67
+ inspectClineInstallation,
68
68
  inspectFxInstallation
69
- } from "../chunk-DMNLFWGY.js";
69
+ } from "../chunk-QNZ6G3LY.js";
70
70
  import {
71
71
  retryAgentCommand
72
- } from "../chunk-S2Z6VWHH.js";
73
- import "../chunk-WUOOZE5S.js";
72
+ } from "../chunk-W5L2ZLHE.js";
73
+ import "../chunk-BEQ3MEE3.js";
74
74
  import {
75
75
  OPENCODE_PLUGIN_PLACEHOLDER,
76
76
  cliOwnsAnyAgentHooks,
77
77
  macAppBridgeAvailable,
78
+ openCodeAskCheck,
79
+ openCodeConfigFile,
78
80
  openCodePluginDir,
79
81
  openCodePluginFile,
80
82
  openCodeWired
81
- } from "../chunk-LTT54NOU.js";
83
+ } from "../chunk-P5HZEGT7.js";
82
84
  import {
83
85
  createIo
84
86
  } from "../chunk-FO3MDD26.js";
85
87
  import {
86
88
  exitOnHelpFlag
87
- } from "../chunk-75ODMNOM.js";
89
+ } from "../chunk-AN7C3CHH.js";
88
90
  import {
89
91
  describeMissingControlPrerequisite,
90
92
  detectProviderLiveCapabilities,
91
93
  expectedLaunchCapabilities,
92
94
  hasSpawnProvider,
93
95
  resolveControlPolicy
94
- } from "../chunk-HOIO66DU.js";
95
- import "../chunk-OY6Z4IKB.js";
96
- import "../chunk-VUFHYMSP.js";
96
+ } from "../chunk-R4FL5JHK.js";
97
+ import "../chunk-HIYLAC3C.js";
98
+ import "../chunk-RABLE5R6.js";
97
99
  import {
98
100
  readLedgerSummary
99
- } from "../chunk-XO3KAH7K.js";
101
+ } from "../chunk-XJIIU36L.js";
100
102
  import {
101
103
  AUTO_UPDATE_DISABLE_ENV,
102
104
  autoUpdateOffReason,
@@ -104,7 +106,7 @@ import {
104
106
  describeAutoUpdateCheck,
105
107
  readAutoUpdateState,
106
108
  takeAutoUpdateAnnouncement
107
- } from "../chunk-PJ34FOIV.js";
109
+ } from "../chunk-DM24VZOI.js";
108
110
  import {
109
111
  compatibleConfigFile,
110
112
  compatibleInstructionsFile,
@@ -112,7 +114,7 @@ import {
112
114
  hasCompatibleHooks,
113
115
  hasCompatibleMcpServer,
114
116
  missingCompatibleHookEvents
115
- } from "../chunk-3QLFB2EY.js";
117
+ } from "../chunk-WY6YAMZW.js";
116
118
  import {
117
119
  daemonHasRemoteProof,
118
120
  daemonServiceManagerAvailable,
@@ -121,7 +123,7 @@ import {
121
123
  readDaemonNeedsLogin,
122
124
  readDaemonStatus,
123
125
  readInstalledDaemonService
124
- } from "../chunk-4WFAP6QN.js";
126
+ } from "../chunk-ADXHPGBZ.js";
125
127
  import {
126
128
  claudeOtherHolders,
127
129
  claudeUnprovenHolds,
@@ -142,56 +144,58 @@ import {
142
144
  liveBridgeProbe,
143
145
  pusharyHookExecutable,
144
146
  resolveBridgeStub
145
- } from "../chunk-SKUSGWFK.js";
147
+ } from "../chunk-GTBWWCCM.js";
146
148
  import {
147
149
  GEMINI_HOOK_BINARY,
148
150
  hasGeminiHooks,
149
151
  missingGeminiHookEvents
150
- } from "../chunk-BQFL2ECS.js";
151
- import "../chunk-XE5N352V.js";
152
- import "../chunk-KLZZI5TU.js";
152
+ } from "../chunk-ANP3DIST.js";
153
+ import "../chunk-SROWUG5W.js";
154
+ import "../chunk-Z3M627TQ.js";
153
155
  import {
154
156
  parseFlags
155
157
  } from "../chunk-NMUI3ZWG.js";
156
158
  import "../chunk-XHKBHWLX.js";
157
- import "../chunk-6ICPEJY5.js";
158
159
  import {
159
160
  keyPrefix,
160
161
  readControlMode,
161
162
  readKeySource
162
- } from "../chunk-IOH2T3CB.js";
163
- import "../chunk-PXAOEFJZ.js";
164
- import "../chunk-VC3HFFMQ.js";
165
- import "../chunk-7GRQGXF4.js";
166
- import "../chunk-TBKHQWIH.js";
163
+ } from "../chunk-ED2SWTPC.js";
164
+ import "../chunk-3UNAPXED.js";
165
+ import "../chunk-3KXBRSL3.js";
166
+ import "../chunk-DTVHZDYM.js";
167
167
  import "../chunk-POFBE6ZY.js";
168
168
  import {
169
169
  callMcpTool,
170
170
  sendMcpRequest
171
- } from "../chunk-ELAK46NR.js";
171
+ } from "../chunk-BKCI53W6.js";
172
172
  import {
173
173
  checkApiKey,
174
174
  describeKeyCheck
175
- } from "../chunk-AB3VAQ25.js";
176
- import "../chunk-VFJSVPNL.js";
175
+ } from "../chunk-UHS5MMAI.js";
176
+ import "../chunk-7ILQX47W.js";
177
177
  import {
178
178
  getMachineId
179
- } from "../chunk-L5CDGXPO.js";
179
+ } from "../chunk-FWS2KLV2.js";
180
180
  import {
181
181
  UsageError
182
182
  } from "../chunk-PPY5N2E6.js";
183
183
  import {
184
184
  EXIT
185
185
  } from "../chunk-KZERVKTD.js";
186
- import "../chunk-V5W3CK7F.js";
187
- import "../chunk-QENTGE75.js";
186
+ import "../chunk-2VADJ6JH.js";
188
187
  import {
188
+ CLINE_AUTO_APPROVE_STEP,
189
+ CLINE_LABEL,
190
+ CLINE_SERVER_NAME_TAKEN,
191
+ CLINE_SETTINGS_REFUSALS,
189
192
  CODEX_HOOK_EVENTS,
190
193
  CODEX_REQUIRED_APPROVAL_EVENTS,
191
194
  autoUpdateState,
192
195
  claudeJson,
193
196
  claudeSettings,
194
197
  claudeSkillDir,
198
+ clineMcpSettings,
195
199
  codexAgentsMd,
196
200
  codexConfigToml,
197
201
  codexHookPositions,
@@ -206,24 +210,26 @@ import {
206
210
  geminiMd,
207
211
  geminiSettings,
208
212
  hasCodexHooks,
213
+ hasInstructionBlock,
209
214
  hermesConfig,
210
215
  hermesConfigReceipt,
211
216
  missingCodexHookEvents,
212
217
  pusharyConfigFile,
213
218
  readCodexMcpAuth,
214
219
  vscodePluginDir
215
- } from "../chunk-MK4USZYQ.js";
220
+ } from "../chunk-ATPJGHUP.js";
216
221
  import {
217
222
  fetchLatestPublishedVersion,
218
223
  readGlobalCliInstall,
224
+ readJsonSafe,
219
225
  resolvePathBinary
220
- } from "../chunk-5LOP4AVD.js";
226
+ } from "../chunk-SCMEVDAR.js";
221
227
  import {
222
228
  getBaseUrl
223
- } from "../chunk-BUQU3OPX.js";
229
+ } from "../chunk-Y64JGYTB.js";
224
230
  import {
225
231
  NPX_LATEST_COMMAND
226
- } from "../chunk-6Z2VR3BA.js";
232
+ } from "../chunk-BAGBCSXA.js";
227
233
  import {
228
234
  commandsPackage,
229
235
  getPackageVersion,
@@ -243,7 +249,7 @@ import {
243
249
  hookCompatibleProfile,
244
250
  isHookActivationReport,
245
251
  redactSecretsFromContent
246
- } from "../chunk-7NCLUA65.js";
252
+ } from "../chunk-MNKIR2ZB.js";
247
253
  import "../chunk-MLKGABMK.js";
248
254
 
249
255
  // bin/pushary-doctor.ts
@@ -580,6 +586,43 @@ var reportHermesStatus = (status) => {
580
586
  if (status.questionsRouted) check(true, "Hermes: questions go through Pushary", `clarify is off in ${config}`);
581
587
  else console.log(` ${warn} Hermes: questions can stop in the terminal ${dim(`(clarify is not in agent.disabled_toolsets in ${config})`)}`);
582
588
  };
589
+ var reportClineKey = (cline, apiKey) => {
590
+ if (cline.runsCommand) {
591
+ console.log(` ${warn} Cline: the pushary server runs through a local command ${dim(`(${retryAgentCommand("cline")} replaces it with a direct connection that carries your key)`)}`);
592
+ } else if (!cline.hasKey && cline.signedIn) {
593
+ check(true, "Cline: signed in through Cline", "OAuth tokens on the pushary server");
594
+ } else if (!cline.hasKey) {
595
+ console.log(` ${warn} Cline: no API key on the pushary server ${dim(`(Cline has to sign in with its Authenticate button; ${retryAgentCommand("cline")} adds your key instead)`)}`);
596
+ } else if (!cline.holdsPusharyKey) {
597
+ console.log(` ${warn} Cline: the pushary server's Authorization header is not a key setup wrote ${dim(`(doctor cannot check a variable or a value you set yourself; ${retryAgentCommand("cline")} writes your key there)`)}`);
598
+ } else if (apiKey && !cline.usesCurrentKey) {
599
+ check(false, "Cline: API key matches active key", `the key in ${clineMcpSettings()} is not the key hooks use (rotated?) \u2014 run pushary upgrade`);
600
+ } else {
601
+ check(true, "Cline: API key linked", "in the pushary server headers");
602
+ }
603
+ };
604
+ var reportCline = (cline, apiKey) => {
605
+ if (cline.configured) {
606
+ checking(CLINE_LABEL);
607
+ check(true, "Cline: Pushary MCP server configured", clineMcpSettings());
608
+ if (cline.switchedOff) {
609
+ console.log(` ${warn} Cline: the pushary server is switched off ${dim(`(turn it on in Cline's MCP Servers, or run ${retryAgentCommand("cline")})`)}`);
610
+ }
611
+ reportClineKey(cline, apiKey);
612
+ if (cline.otherServers.length > 0) {
613
+ console.log(` ${warn} Cline: ${cline.otherServers.map((name) => `"${name}"`).join(", ")} also point at Pushary ${dim("(remove them so Cline does not see the tools twice)")}`);
614
+ }
615
+ console.log(` ${dim(CLINE_AUTO_APPROVE_STEP)}`);
616
+ } else if (cline.nameTakenElsewhere) {
617
+ check(false, "Cline: MCP settings", `${clineMcpSettings()} ${CLINE_SERVER_NAME_TAKEN} \u2014 rename that server in Cline, then run ${retryAgentCommand("cline")}`);
618
+ } else if (cline.read.kind === "refused" && cline.read.mentionsPushary) {
619
+ check(false, "Cline: MCP settings", `${clineMcpSettings()} ${CLINE_SETTINGS_REFUSALS[cline.read.reason]} \u2014 fix it, then run ${retryAgentCommand("cline")}`);
620
+ } else if (cline.read.kind === "unreadable") {
621
+ check(false, "Cline: MCP settings", `${clineMcpSettings()} could not be read \u2014 fix it, then run ${retryAgentCommand("cline")}`);
622
+ } else {
623
+ skipped(CLINE_LABEL, installed("cline") ? "installed, but Pushary is not set up for it" : "not installed");
624
+ }
625
+ };
583
626
  var FX_QUESTION_ROUTING_WARNINGS = {
584
627
  "full-access": "full-access mode ignores permission rules, so fx's terminal question tool stays on; its instructions ask it to use Pushary instead",
585
628
  overridden: `a rule in ${fxSettings()} keeps ${FX_QUESTION_TOOL} on; make "${FX_QUESTION_TOOL}": "deny" the last rule that matches it`
@@ -632,6 +675,26 @@ var extractHookTimeout = (entries, needle) => {
632
675
  return null;
633
676
  };
634
677
  var results = [];
678
+ var OPENCODE_ASK_LABEL = "OpenCode: asks before bash, edit and webfetch";
679
+ var reportOpenCodeAsks = (result) => {
680
+ const file = openCodeConfigFile();
681
+ switch (result.kind) {
682
+ case "asks":
683
+ check(true, OPENCODE_ASK_LABEL, file);
684
+ return;
685
+ case "open":
686
+ if (result.unset.length > 0) {
687
+ console.log(` ${warn} OpenCode runs ${result.unset.join(", ")} without asking, so nothing reaches your phone ${dim(`(add ${result.unset.map((name) => `"${name}": "ask"`).join(", ")} under permission in ${file})`)}`);
688
+ }
689
+ if (result.allowedByPerson.length > 0) {
690
+ console.log(` ${warn} OpenCode is set to run ${result.allowedByPerson.join(", ")} without asking, so those never reach your phone ${dim(`(your rule in ${file}; change it to "ask" to approve from your phone)`)}`);
691
+ }
692
+ return;
693
+ case "unreadable":
694
+ console.log(` ${warn} OpenCode: could not read ${file} to check its permission rules`);
695
+ return;
696
+ }
697
+ };
635
698
  var check = (passed, label, detail, kind = "config") => {
636
699
  results.push({ passed, label, detail, kind });
637
700
  const icon = passed ? pass : fail;
@@ -1221,6 +1284,7 @@ var main = async () => {
1221
1284
  "OpenCode: plugins directory declares ESM",
1222
1285
  existsSync(manifest) ? manifest : `no package.json beside the plugin; Node may load it as CommonJS \u2014 re-run setup`
1223
1286
  );
1287
+ reportOpenCodeAsks(openCodeAskCheck(readJsonSafe(openCodeConfigFile())));
1224
1288
  } else {
1225
1289
  skipped("OpenCode", installed("opencode") ? "installed, but Pushary is not set up for it" : "not installed");
1226
1290
  }
@@ -1251,6 +1315,7 @@ var main = async () => {
1251
1315
  } else {
1252
1316
  skipped("fx", installed("fx") ? "installed, but Pushary is not set up for it" : "not installed");
1253
1317
  }
1318
+ reportCline(inspectClineInstallation(clineMcpSettings(), apiKey), apiKey);
1254
1319
  const hermesPython = resolveHermesPython();
1255
1320
  const hermesStatus = hermesPython ? readHermesStatus(hermesPython) : null;
1256
1321
  const hermesSetupRecorded = existsSync(hermesConfigReceipt());
@@ -1,54 +1,51 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  readHookInput
4
- } from "../chunk-YMZOM6BD.js";
4
+ } from "../chunk-PP7FC3Y7.js";
5
5
  import {
6
6
  announceSubscriptionRequired,
7
7
  isDeferAnswer
8
- } from "../chunk-KL76XWZ7.js";
9
- import "../chunk-T6XQNOZV.js";
10
- import "../chunk-QW3FRUFB.js";
11
- import "../chunk-3QLFB2EY.js";
12
- import "../chunk-4WFAP6QN.js";
13
- import "../chunk-SKUSGWFK.js";
14
- import "../chunk-BQFL2ECS.js";
15
- import "../chunk-XE5N352V.js";
16
- import "../chunk-KLZZI5TU.js";
8
+ } from "../chunk-UMTMFDL2.js";
9
+ import "../chunk-Q2BD4IBX.js";
10
+ import "../chunk-SZBMTOUZ.js";
11
+ import "../chunk-WY6YAMZW.js";
12
+ import "../chunk-ADXHPGBZ.js";
13
+ import "../chunk-GTBWWCCM.js";
14
+ import "../chunk-ANP3DIST.js";
15
+ import "../chunk-SROWUG5W.js";
16
+ import "../chunk-Z3M627TQ.js";
17
17
  import "../chunk-NMUI3ZWG.js";
18
- import "../chunk-BCVCUDFI.js";
19
- import "../chunk-V7N5NOZV.js";
20
- import "../chunk-OJEIS5L2.js";
18
+ import "../chunk-QSW3HAKI.js";
19
+ import "../chunk-TJUJAK5L.js";
20
+ import "../chunk-TK4JU2F7.js";
21
21
  import "../chunk-XHKBHWLX.js";
22
- import "../chunk-6ICPEJY5.js";
23
- import "../chunk-IOH2T3CB.js";
24
- import "../chunk-PXAOEFJZ.js";
25
- import "../chunk-VC3HFFMQ.js";
26
- import "../chunk-7GRQGXF4.js";
22
+ import "../chunk-ED2SWTPC.js";
23
+ import "../chunk-3UNAPXED.js";
24
+ import "../chunk-3KXBRSL3.js";
27
25
  import {
28
26
  askUser,
29
27
  isDecisionStopped,
30
28
  isQuestionLimitRefusal,
31
29
  waitForQuestion
32
- } from "../chunk-TBKHQWIH.js";
30
+ } from "../chunk-DTVHZDYM.js";
33
31
  import "../chunk-POFBE6ZY.js";
34
32
  import {
35
33
  SubscriptionRequiredError
36
- } from "../chunk-ELAK46NR.js";
37
- import "../chunk-AB3VAQ25.js";
38
- import "../chunk-VFJSVPNL.js";
34
+ } from "../chunk-BKCI53W6.js";
35
+ import "../chunk-UHS5MMAI.js";
36
+ import "../chunk-7ILQX47W.js";
39
37
  import {
40
38
  getMachineId
41
- } from "../chunk-L5CDGXPO.js";
39
+ } from "../chunk-FWS2KLV2.js";
42
40
  import "../chunk-PPY5N2E6.js";
43
41
  import "../chunk-KZERVKTD.js";
44
- import "../chunk-V5W3CK7F.js";
45
- import "../chunk-QENTGE75.js";
46
- import "../chunk-MK4USZYQ.js";
47
- import "../chunk-5LOP4AVD.js";
42
+ import "../chunk-2VADJ6JH.js";
43
+ import "../chunk-ATPJGHUP.js";
44
+ import "../chunk-SCMEVDAR.js";
48
45
  import {
49
46
  getApiKey
50
- } from "../chunk-BUQU3OPX.js";
51
- import "../chunk-6Z2VR3BA.js";
47
+ } from "../chunk-Y64JGYTB.js";
48
+ import "../chunk-BAGBCSXA.js";
52
49
  import "../chunk-QTOLNRET.js";
53
50
  import {
54
51
  ELICITATION_ANSWERABLE_MODE,
@@ -60,7 +57,7 @@ import {
60
57
  planElicitationAsk,
61
58
  readElicitationFields,
62
59
  renderElicitationOutput
63
- } from "../chunk-7NCLUA65.js";
60
+ } from "../chunk-MNKIR2ZB.js";
64
61
  import "../chunk-MLKGABMK.js";
65
62
 
66
63
  // bin/pushary-elicitation-hook.ts