pushary 1.9.119 → 1.9.120

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 (133) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/data/cursor-plugin/scripts/pushary-gate.mjs +13 -2
  3. package/data/vscode-plugin/scripts/pushary-gate.mjs +12 -1
  4. package/dist/{api-WWB7ZOLK.js → api-QFUMNTEQ.js} +11 -11
  5. package/dist/bin/pushary-audit.js +3 -3
  6. package/dist/bin/pushary-bell-hook.js +27 -27
  7. package/dist/bin/pushary-bell.js +10 -10
  8. package/dist/bin/pushary-claude.js +25 -25
  9. package/dist/bin/pushary-clean.js +43 -43
  10. package/dist/bin/pushary-codex-bridge.js +21 -21
  11. package/dist/bin/pushary-codex-hook.js +36 -36
  12. package/dist/bin/pushary-codex-session.js +8 -8
  13. package/dist/bin/pushary-codex.js +15 -15
  14. package/dist/bin/pushary-connect.js +28 -28
  15. package/dist/bin/pushary-cowork.js +5 -5
  16. package/dist/bin/pushary-daemon.js +44 -44
  17. package/dist/bin/pushary-disconnect.js +27 -27
  18. package/dist/bin/pushary-display-hook.js +17 -17
  19. package/dist/bin/pushary-doctor.js +47 -47
  20. package/dist/bin/pushary-elicitation-hook.js +27 -27
  21. package/dist/bin/pushary-gemini-bridge.js +15 -15
  22. package/dist/bin/pushary-gemini-hook.js +33 -33
  23. package/dist/bin/pushary-hook.js +33 -33
  24. package/dist/bin/pushary-login.js +22 -22
  25. package/dist/bin/pushary-logout.js +26 -26
  26. package/dist/bin/pushary-mcp.js +12 -12
  27. package/dist/bin/pushary-mode.js +15 -15
  28. package/dist/bin/pushary-notification-hook.js +26 -26
  29. package/dist/bin/pushary-opencode-hook.js +30 -30
  30. package/dist/bin/pushary-permission-denied-hook.js +33 -33
  31. package/dist/bin/pushary-permission-hook.js +33 -33
  32. package/dist/bin/pushary-post-hook.js +26 -26
  33. package/dist/bin/pushary-prompt-hook.js +26 -26
  34. package/dist/bin/pushary-session-end-hook.js +26 -26
  35. package/dist/bin/pushary-session-start-hook.js +35 -35
  36. package/dist/bin/pushary-setup.js +90 -90
  37. package/dist/bin/pushary-stats.js +5 -5
  38. package/dist/bin/pushary-status.js +32 -32
  39. package/dist/bin/pushary-stop-hook.js +26 -26
  40. package/dist/bin/pushary-stopfailure-hook.js +26 -26
  41. package/dist/bin/pushary-suggestions.js +15 -15
  42. package/dist/bin/pushary-transcript-register.js +17 -17
  43. package/dist/bin/pushary-transcripts.js +25 -25
  44. package/dist/bin/pushary-upgrade.js +43 -43
  45. package/dist/bin/pushary-wait.js +17 -17
  46. package/dist/bin/pushary.js +7 -7
  47. package/dist/{chunk-RIAELZYW.js → chunk-2AMSWODQ.js} +2 -2
  48. package/dist/{chunk-PNSIMPC7.js → chunk-2ZT4XV4I.js} +6 -6
  49. package/dist/{chunk-Z3OG44Z4.js → chunk-33NEYAK2.js} +4 -4
  50. package/dist/{chunk-SE7P5BBK.js → chunk-363YZ5WJ.js} +1 -1
  51. package/dist/{chunk-XNCKBVZX.js → chunk-3DD44QTA.js} +5 -5
  52. package/dist/{chunk-COXNQUDP.js → chunk-3GFJ7CXQ.js} +4 -4
  53. package/dist/{chunk-U32N5JZO.js → chunk-47HCNA5U.js} +1 -1
  54. package/dist/{chunk-SQRS4IF2.js → chunk-4DSJF5JD.js} +3 -3
  55. package/dist/{chunk-UHAUC7EO.js → chunk-4FLMGGWB.js} +2 -2
  56. package/dist/{chunk-MEPYLTWF.js → chunk-5JZCFZUT.js} +10 -10
  57. package/dist/{chunk-GAOUWLYN.js → chunk-5KCUQ3B7.js} +3 -3
  58. package/dist/{chunk-K5WTTEIQ.js → chunk-5NHWNILG.js} +5 -5
  59. package/dist/{chunk-W5ZUDPKV.js → chunk-6CJ7D6EQ.js} +5 -5
  60. package/dist/{chunk-TZYVXTLN.js → chunk-6FR5ZYMS.js} +1 -1
  61. package/dist/{chunk-PJSFKKZ5.js → chunk-7VRL6XYM.js} +1 -1
  62. package/dist/{chunk-JKS4MN47.js → chunk-7YRKM4AB.js} +6 -6
  63. package/dist/{chunk-PDAOZ2NF.js → chunk-A5YOWKPR.js} +10 -10
  64. package/dist/{chunk-YCCLWG7G.js → chunk-AIABYHHZ.js} +6 -6
  65. package/dist/{chunk-VMM6JCNQ.js → chunk-B4M2XZNQ.js} +2 -2
  66. package/dist/{chunk-HYTDNEXV.js → chunk-BYP2R2PF.js} +1 -1
  67. package/dist/{chunk-KILSIJTF.js → chunk-BZ6N5DDZ.js} +60 -16
  68. package/dist/{chunk-YZ7V2LVG.js → chunk-CPBS6LS3.js} +3 -3
  69. package/dist/{chunk-XBH6OKHD.js → chunk-EDNCFLR7.js} +3 -3
  70. package/dist/{chunk-V52J2THT.js → chunk-EG2E2562.js} +1 -1
  71. package/dist/{chunk-VRZOUCIK.js → chunk-EU4NV7SS.js} +2 -2
  72. package/dist/{chunk-ZLUAXGAA.js → chunk-F24QURGP.js} +4 -4
  73. package/dist/{chunk-4SZM2HRA.js → chunk-H4LCCX7W.js} +6 -6
  74. package/dist/{chunk-YZESBU7F.js → chunk-HHZSB6KL.js} +151 -6
  75. package/dist/{chunk-SNKC2IQZ.js → chunk-HSFTTGOB.js} +2 -2
  76. package/dist/{chunk-GW3PE52Q.js → chunk-HVGN7TRN.js} +1 -1
  77. package/dist/{chunk-AGXOTZID.js → chunk-INKDRMSK.js} +5 -5
  78. package/dist/{chunk-JJNF6QU4.js → chunk-IYUAMUO6.js} +1 -1
  79. package/dist/{chunk-6YLVNFQZ.js → chunk-J4AJVM5F.js} +3 -3
  80. package/dist/{chunk-EFFH2FYG.js → chunk-J6ACLE2A.js} +2 -2
  81. package/dist/{chunk-GBVTVTDF.js → chunk-K4RIBZ32.js} +1 -1
  82. package/dist/{chunk-BQ673OOD.js → chunk-KESS6HAK.js} +2 -2
  83. package/dist/{chunk-NASQPMXW.js → chunk-KG7UZSCD.js} +9 -9
  84. package/dist/{chunk-EP6I3MQY.js → chunk-L37Q4BR6.js} +4 -4
  85. package/dist/{chunk-R3RTISDD.js → chunk-MZX35RFX.js} +1 -1
  86. package/dist/{chunk-5T5T4YXM.js → chunk-NBKH6SKN.js} +1 -1
  87. package/dist/{chunk-ZTVBM3EZ.js → chunk-NVOQBKIL.js} +4 -4
  88. package/dist/{chunk-6KX2H4I5.js → chunk-NXWQZBOK.js} +3 -3
  89. package/dist/{chunk-KOZBVXXC.js → chunk-ODXZPMKN.js} +3 -3
  90. package/dist/{chunk-VFZ2PE6U.js → chunk-PEMESJZY.js} +3 -3
  91. package/dist/{chunk-FPG7X2GS.js → chunk-PTONPJWL.js} +4 -4
  92. package/dist/{chunk-KVDN4U6W.js → chunk-RHTAI4XP.js} +10 -10
  93. package/dist/{chunk-L3MCQSES.js → chunk-RM7MNCCA.js} +5 -5
  94. package/dist/{chunk-3IESC326.js → chunk-RWS4DRFK.js} +3 -3
  95. package/dist/{chunk-R67NTMBY.js → chunk-SJPH24TK.js} +8 -8
  96. package/dist/{chunk-ISVHV2DP.js → chunk-SSTO42XS.js} +1 -1
  97. package/dist/{chunk-2UE2NDCX.js → chunk-SUI5JE6T.js} +1 -1
  98. package/dist/{chunk-3B7S2H4R.js → chunk-T57CIR6H.js} +1 -1
  99. package/dist/{chunk-G5FQU2XF.js → chunk-TAHUCUY3.js} +6 -6
  100. package/dist/{chunk-7CJ7W2RH.js → chunk-UFRRAAYD.js} +4 -4
  101. package/dist/{chunk-W6LKC5YD.js → chunk-UZL3VQCE.js} +5 -5
  102. package/dist/{chunk-2C45MJGK.js → chunk-VKRRUT45.js} +13 -6
  103. package/dist/{chunk-SSBETUYZ.js → chunk-W4MZBZU3.js} +3 -3
  104. package/dist/{chunk-TRDHHF3A.js → chunk-W744DTUT.js} +17 -0
  105. package/dist/{chunk-EISUEJDT.js → chunk-WFHUECGB.js} +6 -6
  106. package/dist/{chunk-G4OVFWU4.js → chunk-XOPOX5QY.js} +46 -28
  107. package/dist/{chunk-RGXFBS56.js → chunk-XRRY45XB.js} +3 -3
  108. package/dist/{chunk-TLCJCP5R.js → chunk-XSSG5JLJ.js} +1 -1
  109. package/dist/{chunk-MYNLU6DV.js → chunk-XUAGV5VH.js} +2 -2
  110. package/dist/{chunk-NVV3YUTX.js → chunk-YOSATSUD.js} +2 -2
  111. package/dist/{chunk-CXIYGD33.js → chunk-YQGPBLIT.js} +2 -2
  112. package/dist/{chunk-4D23TNCL.js → chunk-YQUJQGJU.js} +4 -4
  113. package/dist/{chunk-67I7QRQB.js → chunk-YZORQXN7.js} +1 -1
  114. package/dist/{chunk-B7BOENW7.js → chunk-ZMKZ5WHS.js} +1 -1
  115. package/dist/{chunk-DXJUASTS.js → chunk-ZR35L635.js} +2 -2
  116. package/dist/{chunk-CBLFIWPI.js → chunk-ZRTUS6WD.js} +12 -5
  117. package/dist/{chunk-4HDX77ND.js → chunk-ZV7G73KH.js} +3 -3
  118. package/dist/{chunk-5HKU4VUL.js → chunk-ZWUVJ3DV.js} +3 -3
  119. package/dist/{codex-app-cards-switch-J6EULXO5.js → codex-app-cards-switch-545ISCGQ.js} +12 -12
  120. package/dist/{codex-card-routing-XNJB6573.js → codex-card-routing-IKNAEEMC.js} +2 -2
  121. package/dist/{codex-desktop-launch-46ELENBQ.js → codex-desktop-launch-VQNI4GUS.js} +1 -1
  122. package/dist/{codex-session-launch-R5FHFWAG.js → codex-session-launch-OGOGHTM7.js} +18 -18
  123. package/dist/{config-RKWDMDRY.js → config-VGWGOR2V.js} +3 -3
  124. package/dist/{global-upgrade-E65GJQS6.js → global-upgrade-GUHXKJPO.js} +9 -9
  125. package/dist/{identity-JRGY2KS6.js → identity-FORDJUYW.js} +4 -4
  126. package/dist/{live-capabilities-SOO6PD7Y.js → live-capabilities-VA3VXZOZ.js} +4 -4
  127. package/dist/{paths-G7NZODAY.js → paths-5XZPI4LD.js} +3 -3
  128. package/dist/{reapply-YKN5BKIP.js → reapply-77JJ3QV2.js} +28 -28
  129. package/dist/src/index.d.ts +1 -1
  130. package/dist/src/index.js +32 -32
  131. package/dist/{upgrade-lock-YKAZI3BH.js → upgrade-lock-EEPLQBLA.js} +4 -4
  132. package/dist/{usage-QWYNOIU6.js → usage-27IDH6UH.js} +3 -3
  133. package/package.json +1 -1
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  CLAUDE_CODE_AGENT
3
- } from "./chunk-G4OVFWU4.js";
3
+ } from "./chunk-XOPOX5QY.js";
4
4
  import {
5
5
  addGeminiMcpServer,
6
6
  removeGeminiMcpServer
7
- } from "./chunk-COXNQUDP.js";
7
+ } from "./chunk-3GFJ7CXQ.js";
8
8
  import {
9
9
  compatibleToolLookup
10
- } from "./chunk-GW3PE52Q.js";
10
+ } from "./chunk-HVGN7TRN.js";
11
11
  import {
12
12
  CLAUDE_HOOK_EVENTS,
13
13
  PUSHARY_MCP_URL,
@@ -19,7 +19,7 @@ import {
19
19
  isPusharyHook,
20
20
  registerHookEntry,
21
21
  removeClaudeMcpServers
22
- } from "./chunk-CBLFIWPI.js";
22
+ } from "./chunk-ZRTUS6WD.js";
23
23
  import {
24
24
  HOOK_COMPATIBLE_PROFILES,
25
25
  PHONE_ANSWERED_TOOLS,
@@ -30,7 +30,7 @@ import {
30
30
  pusharyMissingReason,
31
31
  refusalOutput,
32
32
  withHookHoldBudget
33
- } from "./chunk-TRDHHF3A.js";
33
+ } from "./chunk-W744DTUT.js";
34
34
 
35
35
  // src/config-document.ts
36
36
  import { parse, stringify } from "smol-toml";
@@ -56,6 +56,150 @@ var serializeConfigDocument = (value, format) => format === "toml" ? stringify(v
56
56
  // src/compatible-config.ts
57
57
  import { homedir } from "os";
58
58
  import { join } from "path";
59
+
60
+ // ../contracts/src/agent-enforcement.ts
61
+ var TOOL_CALL_BLOCK = {
62
+ beforeMatchedCalls: "before_matched_calls",
63
+ whenAgentAsks: "when_agent_asks",
64
+ cannotBlock: "cannot_block"
65
+ };
66
+ var LOCAL_PROMPT = {
67
+ agentsOwnPrompt: "agents_own_prompt",
68
+ variesByEvent: "varies_by_event",
69
+ refusalInstead: "refusal_instead",
70
+ noHook: "no_hook"
71
+ };
72
+ var HOOK_FAILURE = {
73
+ agentsOwnApproval: "agents_own_approval",
74
+ variesByEvent: "varies_by_event",
75
+ refusedOnPosix: "refused_on_posix",
76
+ notVerifiableInThisRepo: "not_verifiable_in_this_repo",
77
+ noHook: "no_hook"
78
+ };
79
+ var NO_HOOK_NOTHING_GATED = "Everything. There is no hook, so the agent only reaches a person when it chooses to call Pushary.";
80
+ var NO_HOOK = {
81
+ blocksToolCallBeforeItRuns: TOOL_CALL_BLOCK.cannotBlock,
82
+ phoneCanAnswerTheBlock: false,
83
+ localPrompt: LOCAL_PROMPT.noHook,
84
+ whenHookIsMissing: HOOK_FAILURE.noHook,
85
+ whenHookCrashes: HOOK_FAILURE.noHook,
86
+ gatedTools: [],
87
+ notGated: NO_HOOK_NOTHING_GATED
88
+ };
89
+ var HOOK_DECIDES_BEFORE_THE_CALL = {
90
+ blocksToolCallBeforeItRuns: TOOL_CALL_BLOCK.beforeMatchedCalls,
91
+ phoneCanAnswerTheBlock: true
92
+ };
93
+ var FAILS_TO_THE_AGENTS_OWN_APPROVAL = {
94
+ whenHookIsMissing: HOOK_FAILURE.agentsOwnApproval,
95
+ whenHookCrashes: HOOK_FAILURE.agentsOwnApproval
96
+ };
97
+ var CLAUDE_SHAPED_GATED_TOOLS = ["Bash", "Write", "Edit", "MultiEdit", "NotebookEdit", "PowerShell", "Monitor", "mcp__.*"];
98
+ var CLAUDE_SHAPED_NOT_GATED = "Any tool outside the matcher, such as reads, searches and web fetches. Those only reach a person if this agent raises its own prompt and it sends PermissionRequest.";
99
+ var COMPATIBLE_HOOK_AGENT = {
100
+ ...HOOK_DECIDES_BEFORE_THE_CALL,
101
+ ...FAILS_TO_THE_AGENTS_OWN_APPROVAL,
102
+ localPrompt: LOCAL_PROMPT.agentsOwnPrompt,
103
+ gatedTools: CLAUDE_SHAPED_GATED_TOOLS,
104
+ notGated: CLAUDE_SHAPED_NOT_GATED
105
+ };
106
+ var AGENT_ENFORCEMENT = {
107
+ claude_code: {
108
+ ...HOOK_DECIDES_BEFORE_THE_CALL,
109
+ ...FAILS_TO_THE_AGENTS_OWN_APPROVAL,
110
+ localPrompt: LOCAL_PROMPT.agentsOwnPrompt,
111
+ gatedTools: ["Bash", "Write", "Edit", "MultiEdit", "NotebookEdit", "PowerShell", "Monitor", "AskUserQuestion", "ExitPlanMode"],
112
+ notGated: "Reads, searches, WebFetch, WebSearch, Task, TodoWrite and third-party MCP tools reach a person only through PermissionRequest, when Claude Code would have asked anyway. In plan, auto and dontAsk modes PreToolUse steps aside unless a scope question or a Team route applies. It also steps aside for edits under acceptEdits and for calls that a Claude Code allowlist rule owns. Under bypassPermissions no opinion means the call runs."
113
+ },
114
+ codex: {
115
+ ...HOOK_DECIDES_BEFORE_THE_CALL,
116
+ ...FAILS_TO_THE_AGENTS_OWN_APPROVAL,
117
+ localPrompt: LOCAL_PROMPT.variesByEvent,
118
+ gatedTools: ["Bash", "apply_patch", "mcp__.*", "request_user_input", "request_user_input_async"],
119
+ notGated: "Any other tool, and every hook until Codex trusts it. PreToolUse can only deny; a hand-back there is refused, and only PermissionRequest falls through to the Codex prompt. With the auto_review approvals reviewer, or when a native mode defers the call, the hook passes it ungated unless a scope question applies. Under bypass no opinion means the call runs."
120
+ },
121
+ gemini_cli: {
122
+ ...HOOK_DECIDES_BEFORE_THE_CALL,
123
+ ...FAILS_TO_THE_AGENTS_OWN_APPROVAL,
124
+ localPrompt: LOCAL_PROMPT.agentsOwnPrompt,
125
+ gatedTools: ["run_shell_command", "write_file", "replace", "mcp_.*"],
126
+ notGated: "read_file and every other built-in tool outside the BeforeTool matcher. The wire has no ask, so a hand-back is empty output, a Gemini running without prompts then runs the call, and a bridge-launched session, which has no prompt, is refused instead."
127
+ },
128
+ cursor: {
129
+ ...HOOK_DECIDES_BEFORE_THE_CALL,
130
+ localPrompt: LOCAL_PROMPT.variesByEvent,
131
+ whenHookIsMissing: HOOK_FAILURE.variesByEvent,
132
+ whenHookCrashes: HOOK_FAILURE.variesByEvent,
133
+ gatedTools: ["Shell", "MCP:*", "Write", "Delete", "Edit"],
134
+ notGated: "beforeReadFile is deliberately not registered, so file reads are not gated. preToolUse has no ask, so a file edit nobody can decide is refused where shell and MCP fall back to the Cursor prompt."
135
+ },
136
+ vscode: {
137
+ ...HOOK_DECIDES_BEFORE_THE_CALL,
138
+ ...FAILS_TO_THE_AGENTS_OWN_APPROVAL,
139
+ localPrompt: LOCAL_PROMPT.agentsOwnPrompt,
140
+ gatedTools: [".*"],
141
+ notGated: "Pushary's own tools. Every other named tool reaches the policy, and a read-only tool passes when the gate has no verdict."
142
+ },
143
+ opencode: {
144
+ blocksToolCallBeforeItRuns: TOOL_CALL_BLOCK.whenAgentAsks,
145
+ phoneCanAnswerTheBlock: true,
146
+ ...FAILS_TO_THE_AGENTS_OWN_APPROVAL,
147
+ localPrompt: LOCAL_PROMPT.agentsOwnPrompt,
148
+ gatedTools: ["bash", "edit", "webfetch"],
149
+ notGated: "Anything OpenCode does not raise as permission.asked. A person's own allow rule for bash, edit or webfetch is kept, and then those are not held either."
150
+ },
151
+ hermes: {
152
+ blocksToolCallBeforeItRuns: TOOL_CALL_BLOCK.whenAgentAsks,
153
+ phoneCanAnswerTheBlock: true,
154
+ localPrompt: LOCAL_PROMPT.agentsOwnPrompt,
155
+ whenHookIsMissing: HOOK_FAILURE.notVerifiableInThisRepo,
156
+ whenHookCrashes: HOOK_FAILURE.agentsOwnApproval,
157
+ gatedTools: [],
158
+ notGated: "Everything Hermes does not flag as a dangerous command, unless named in PUSHARY_GATE_TOOLS, which is empty by default. That list refuses on an error, while the approval transport hands back to Hermes."
159
+ },
160
+ qwen_code: COMPATIBLE_HOOK_AGENT,
161
+ codebuddy: COMPATIBLE_HOOK_AGENT,
162
+ qoder: COMPATIBLE_HOOK_AGENT,
163
+ droid: {
164
+ ...COMPATIBLE_HOOK_AGENT,
165
+ notGated: "Any tool outside the matcher, such as reads, searches and web fetches. Droid registers no PermissionRequest, so those never reach a person through Pushary."
166
+ },
167
+ devin: {
168
+ ...COMPATIBLE_HOOK_AGENT,
169
+ localPrompt: LOCAL_PROMPT.refusalInstead,
170
+ gatedTools: [...CLAUDE_SHAPED_GATED_TOOLS, "mcp_call_tool", "write_to_process"],
171
+ notGated: "Any tool outside the matcher, such as reads, searches and web fetches. Devin registers no PermissionRequest, so those never reach a person through Pushary. Its wire turns an ask into a block."
172
+ },
173
+ antigravity_cli: {
174
+ ...HOOK_DECIDES_BEFORE_THE_CALL,
175
+ localPrompt: LOCAL_PROMPT.refusalInstead,
176
+ whenHookIsMissing: HOOK_FAILURE.refusedOnPosix,
177
+ whenHookCrashes: HOOK_FAILURE.notVerifiableInThisRepo,
178
+ gatedTools: ["Bash", "Write", "Edit", "MultiEdit", "NotebookEdit", "PowerShell", "Monitor", "call_mcp_tool", "manage_task"],
179
+ notGated: "view_file, read_url_content, search_web, list_resources and read_resource. Deleting the hook entry leaves always-proceed on with nothing watching, and the hook-file guard only covers a missing binary, and not on Windows. A caught error is refused, but nothing here shows what agy does when the hook process dies or exits non-zero."
180
+ },
181
+ grok: {
182
+ ...HOOK_DECIDES_BEFORE_THE_CALL,
183
+ localPrompt: LOCAL_PROMPT.agentsOwnPrompt,
184
+ whenHookIsMissing: HOOK_FAILURE.refusedOnPosix,
185
+ whenHookCrashes: HOOK_FAILURE.agentsOwnApproval,
186
+ gatedTools: [".*"],
187
+ notGated: "Nothing at the matcher, but Grok fails open if it kills the hook or cannot start it, the missing-binary guard does not refuse on Windows, and Grok's own permission checks still apply after a phone approval. Its question and plan dialogs stay in Grok."
188
+ },
189
+ claude_chat: NO_HOOK,
190
+ claude_cowork: NO_HOOK,
191
+ chatgpt: NO_HOOK,
192
+ fx: NO_HOOK,
193
+ cline: NO_HOOK,
194
+ grok_bot: NO_HOOK,
195
+ windsurf: NO_HOOK,
196
+ unknown: NO_HOOK,
197
+ lovable: NO_HOOK,
198
+ mcp: NO_HOOK,
199
+ http: NO_HOOK
200
+ };
201
+
202
+ // src/compatible-config.ts
59
203
  var hasCompatibleMcpServer = (profile, contents) => {
60
204
  if (!profile.mcp) return false;
61
205
  const document = parseConfigDocument(contents, profile.mcp.file.format);
@@ -210,7 +354,8 @@ var commandFor = (profile, definition, resolve) => {
210
354
  return withHookHoldBudget(command, holdBudgetOf(definition));
211
355
  };
212
356
  var writesBareHandler = (profile, definition) => profile.nonToolEntries === "handler" && !TOOL_MATCHED_EVENTS.has(definition.event);
213
- var guardFor = (profile, definition, path) => isSoleGateEvent(profile, definition) || profile.source === "grok" && definition.delivery === "approval" ? guardBinaryRefusing(path, refusalOutput(profile, pusharyMissingReason(profile))) : guardBinary(path);
357
+ var refusesWhenHookIsMissing = (profile, definition) => definition.delivery === "approval" && AGENT_ENFORCEMENT[profile.agentType].whenHookIsMissing === HOOK_FAILURE.refusedOnPosix;
358
+ var guardFor = (profile, definition, path) => refusesWhenHookIsMissing(profile, definition) ? guardBinaryRefusing(path, refusalOutput(profile, pusharyMissingReason(profile))) : guardBinary(path);
214
359
  var entryFor = (profile, definition, resolve) => {
215
360
  const handler = { type: "command", command: commandFor(profile, definition, resolve), timeout: definition.timeout };
216
361
  if (writesBareHandler(profile, definition)) return handler;
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  pusharyDir
3
- } from "./chunk-CBLFIWPI.js";
3
+ } from "./chunk-ZRTUS6WD.js";
4
4
  import {
5
5
  readJsonSafe
6
6
  } from "./chunk-T5I4PKOQ.js";
7
7
  import {
8
8
  isRecord
9
- } from "./chunk-TRDHHF3A.js";
9
+ } from "./chunk-W744DTUT.js";
10
10
 
11
11
  // src/process-ownership.ts
12
12
  import { createHash, randomUUID } from "crypto";
@@ -24,7 +24,7 @@ import {
24
24
  reportableSessionId,
25
25
  toToolLookup,
26
26
  truncateLine
27
- } from "./chunk-TRDHHF3A.js";
27
+ } from "./chunk-W744DTUT.js";
28
28
 
29
29
  // ../hook-mapping/src/commit-receipt.ts
30
30
  var COMMIT_OUTPUT_MAX_LENGTH = 65536;
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  compatibleConfigFile
3
- } from "./chunk-YZESBU7F.js";
3
+ } from "./chunk-HHZSB6KL.js";
4
4
  import {
5
5
  hookOwnerOf,
6
6
  hookOwnerOfCommands
7
- } from "./chunk-COXNQUDP.js";
7
+ } from "./chunk-3GFJ7CXQ.js";
8
8
  import {
9
9
  AGENT_CHOICES
10
- } from "./chunk-2UE2NDCX.js";
10
+ } from "./chunk-SUI5JE6T.js";
11
11
  import {
12
12
  bridgeStub,
13
13
  claudeSettings,
@@ -19,7 +19,7 @@ import {
19
19
  resolveBridgeStub,
20
20
  vscodePluginDir,
21
21
  windowsNodeLauncherFor
22
- } from "./chunk-CBLFIWPI.js";
22
+ } from "./chunk-ZRTUS6WD.js";
23
23
  import {
24
24
  readJsonSafe
25
25
  } from "./chunk-T5I4PKOQ.js";
@@ -29,7 +29,7 @@ import {
29
29
  OPENCODE_APPROVAL_EVENT,
30
30
  hookCompatibleProfile,
31
31
  isRecord
32
- } from "./chunk-TRDHHF3A.js";
32
+ } from "./chunk-W744DTUT.js";
33
33
 
34
34
  // src/opencode-plugin.ts
35
35
  var OPENCODE_PLUGIN_MARKER = "pushary-opencode-plugin w1";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  readConfigFileKey
3
- } from "./chunk-YZ7V2LVG.js";
3
+ } from "./chunk-CPBS6LS3.js";
4
4
 
5
5
  // src/bell/fleet.ts
6
6
  import { closeSync, constants, futimesSync, lstatSync, mkdirSync, openSync, readdirSync, unlinkSync } from "fs";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  SETUP_FLAGS
3
- } from "./chunk-2UE2NDCX.js";
3
+ } from "./chunk-SUI5JE6T.js";
4
4
  import {
5
5
  parseFlags
6
6
  } from "./chunk-YPY4YCIZ.js";
@@ -9,7 +9,7 @@ import {
9
9
  } from "./chunk-YU2EUD7O.js";
10
10
  import {
11
11
  NPX_LATEST_COMMAND
12
- } from "./chunk-PJSFKKZ5.js";
12
+ } from "./chunk-7VRL6XYM.js";
13
13
  import {
14
14
  CLAUDE_CONNECTOR_GUIDE,
15
15
  CLAUDE_CONNECTOR_STEPS,
@@ -17,7 +17,7 @@ import {
17
17
  CLAUDE_CONNECTOR_URL,
18
18
  COWORK_CONNECTOR_LIMIT,
19
19
  COWORK_STANDING_INSTRUCTIONS
20
- } from "./chunk-TRDHHF3A.js";
20
+ } from "./chunk-W744DTUT.js";
21
21
 
22
22
  // src/cli/cowork.ts
23
23
  import { readFileSync } from "fs";
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  autoUpdateLock
3
- } from "./chunk-CBLFIWPI.js";
3
+ } from "./chunk-ZRTUS6WD.js";
4
4
  import {
5
5
  installPackageGlobally,
6
6
  npmErrorMessage,
7
7
  npmExitedOnPermissionDenied
8
- } from "./chunk-KOZBVXXC.js";
8
+ } from "./chunk-ODXZPMKN.js";
9
9
  import {
10
10
  writeJsonAtomic
11
11
  } from "./chunk-T5I4PKOQ.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  DEFAULT_SESSION
3
- } from "./chunk-G4OVFWU4.js";
3
+ } from "./chunk-XOPOX5QY.js";
4
4
 
5
5
  // src/answer.ts
6
6
  var isDeferAnswer = (value) => value === "defer";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  absoluteUrl
3
- } from "./chunk-4HDX77ND.js";
3
+ } from "./chunk-ZV7G73KH.js";
4
4
  import {
5
5
  KEY_SCOPE
6
- } from "./chunk-TRDHHF3A.js";
6
+ } from "./chunk-W744DTUT.js";
7
7
 
8
8
  // src/cli/approval-settings-pages.ts
9
9
  var API_KEYS_PATH = "/dashboard/agent/settings";
@@ -6,21 +6,21 @@ import {
6
6
  McpToolError,
7
7
  SubscriptionRequiredError,
8
8
  callMcpTool
9
- } from "./chunk-W6LKC5YD.js";
9
+ } from "./chunk-UZL3VQCE.js";
10
10
  import {
11
11
  installNetworkDefaults,
12
12
  isNetworkFailure
13
- } from "./chunk-RGXFBS56.js";
13
+ } from "./chunk-XRRY45XB.js";
14
14
  import {
15
15
  fetchAsCredential
16
- } from "./chunk-U32N5JZO.js";
16
+ } from "./chunk-47HCNA5U.js";
17
17
  import {
18
18
  clientReportClaims
19
- } from "./chunk-CBLFIWPI.js";
19
+ } from "./chunk-ZRTUS6WD.js";
20
20
  import {
21
21
  getApiKey,
22
22
  getBaseUrl
23
- } from "./chunk-R3RTISDD.js";
23
+ } from "./chunk-MZX35RFX.js";
24
24
  import {
25
25
  ASK_AGENT_NAME_MAX,
26
26
  CLIENT_REPORT_PATH,
@@ -29,7 +29,7 @@ import {
29
29
  TOOL_FAILURE_CODES,
30
30
  degradedLine,
31
31
  truncateLine
32
- } from "./chunk-TRDHHF3A.js";
32
+ } from "./chunk-W744DTUT.js";
33
33
 
34
34
  // src/api.ts
35
35
  import { randomUUID } from "crypto";
@@ -327,13 +327,13 @@ var claimBlockedAction = async (apiKey, request, timeoutMs) => {
327
327
  };
328
328
 
329
329
  export {
330
- isPolicyConfig,
331
- isAskUserResponse,
332
- isWaitForAnswerResponse,
333
330
  reportClientError,
334
331
  exitAfterClientReports,
335
332
  clientErrorKindOf,
336
333
  writeDegraded,
334
+ isPolicyConfig,
335
+ isAskUserResponse,
336
+ isWaitForAnswerResponse,
337
337
  isDecisionStopped,
338
338
  isAwayPaused,
339
339
  isLocalQuestionHandoff,
@@ -1,17 +1,17 @@
1
1
  import {
2
2
  pusharyHookExecutable
3
- } from "./chunk-COXNQUDP.js";
3
+ } from "./chunk-3GFJ7CXQ.js";
4
4
  import {
5
5
  bridgeResolvesToApp,
6
6
  cursorUserHooks,
7
7
  executableFileName,
8
8
  isBridgeLocator,
9
9
  liveBridgeProbe
10
- } from "./chunk-CBLFIWPI.js";
10
+ } from "./chunk-ZRTUS6WD.js";
11
11
  import {
12
12
  atLeast,
13
13
  parseVersion
14
- } from "./chunk-KOZBVXXC.js";
14
+ } from "./chunk-ODXZPMKN.js";
15
15
  import {
16
16
  CURSOR_GATE_COVERAGE,
17
17
  CURSOR_GATE_SCRIPT,
@@ -21,7 +21,7 @@ import {
21
21
  isCursorHookPayload,
22
22
  isRecord,
23
23
  toolsCoveredByGateEntry
24
- } from "./chunk-TRDHHF3A.js";
24
+ } from "./chunk-W744DTUT.js";
25
25
 
26
26
  // src/cursor-gate-registration.ts
27
27
  import { dirname, isAbsolute, join, resolve } from "path";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  NPX_LATEST_COMMAND
3
- } from "./chunk-PJSFKKZ5.js";
3
+ } from "./chunk-7VRL6XYM.js";
4
4
 
5
5
  // src/config.ts
6
6
  import { readFileSync } from "fs";
@@ -7,7 +7,7 @@ import {
7
7
  } from "./chunk-BG4HHB7E.js";
8
8
  import {
9
9
  redactSecretsFromContent
10
- } from "./chunk-TRDHHF3A.js";
10
+ } from "./chunk-W744DTUT.js";
11
11
 
12
12
  // src/cli/json.ts
13
13
  var writeStdoutFully = (text) => new Promise((resolve, reject) => {
@@ -1,20 +1,20 @@
1
1
  import {
2
2
  openCodeConfigDirFrom
3
- } from "./chunk-AGXOTZID.js";
3
+ } from "./chunk-INKDRMSK.js";
4
4
  import {
5
5
  nativeClaudeInstallPath
6
6
  } from "./chunk-ROVLRXBI.js";
7
7
  import {
8
8
  grokHome
9
- } from "./chunk-YZESBU7F.js";
9
+ } from "./chunk-HHZSB6KL.js";
10
10
  import {
11
11
  claudeConfigDir,
12
12
  clineDataDirectory,
13
13
  codexHomeFrom
14
- } from "./chunk-CBLFIWPI.js";
14
+ } from "./chunk-ZRTUS6WD.js";
15
15
  import {
16
16
  HOOK_COMPATIBLE_PROFILES
17
- } from "./chunk-TRDHHF3A.js";
17
+ } from "./chunk-W744DTUT.js";
18
18
 
19
19
  // src/vscode-config.ts
20
20
  import { homedir } from "os";
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  parseSseMessages
3
- } from "./chunk-W6LKC5YD.js";
3
+ } from "./chunk-UZL3VQCE.js";
4
4
  import {
5
5
  fetchAsCredential
6
- } from "./chunk-U32N5JZO.js";
6
+ } from "./chunk-47HCNA5U.js";
7
7
  import {
8
8
  NPX_LATEST_COMMAND
9
- } from "./chunk-PJSFKKZ5.js";
9
+ } from "./chunk-7VRL6XYM.js";
10
10
 
11
11
  // src/mcp-stdio-bridge.ts
12
12
  var MCP_BRIDGE_BINARY = "pushary-mcp";
@@ -399,9 +399,9 @@ var installGlobally = (options) => {
399
399
  }
400
400
  const started = (async () => {
401
401
  if (!npmIsOnPath()) throw new NpmMissingError();
402
- const { withUpgradeLock } = await import("./global-upgrade-E65GJQS6.js");
403
- const { installWithUpgradeLock, ownsUpgradeLock } = await import("./upgrade-lock-YKAZI3BH.js");
404
- const { autoUpdateLock } = await import("./paths-G7NZODAY.js");
402
+ const { withUpgradeLock } = await import("./global-upgrade-GUHXKJPO.js");
403
+ const { installWithUpgradeLock, ownsUpgradeLock } = await import("./upgrade-lock-EEPLQBLA.js");
404
+ const { autoUpdateLock } = await import("./paths-5XZPI4LD.js");
405
405
  let result = "skipped";
406
406
  const install = async () => {
407
407
  const platform = process.platform;
@@ -4,15 +4,15 @@ import {
4
4
  claimThrottle,
5
5
  releaseThrottle,
6
6
  reportEvent
7
- } from "./chunk-G4OVFWU4.js";
7
+ } from "./chunk-XOPOX5QY.js";
8
8
  import {
9
9
  deriveToolTarget,
10
10
  permissionDeniedAction
11
- } from "./chunk-GW3PE52Q.js";
11
+ } from "./chunk-HVGN7TRN.js";
12
12
  import {
13
13
  machineDecisionFor,
14
14
  wireVerdictFor
15
- } from "./chunk-TRDHHF3A.js";
15
+ } from "./chunk-W744DTUT.js";
16
16
 
17
17
  // src/machine-decision-audit.ts
18
18
  import { basename } from "path";
@@ -1,19 +1,19 @@
1
1
  import {
2
2
  macAppBridgeAvailable
3
- } from "./chunk-AGXOTZID.js";
3
+ } from "./chunk-INKDRMSK.js";
4
4
  import {
5
5
  keyPrefix
6
- } from "./chunk-YZ7V2LVG.js";
6
+ } from "./chunk-CPBS6LS3.js";
7
7
  import {
8
8
  bridgeAgentKey
9
- } from "./chunk-CBLFIWPI.js";
9
+ } from "./chunk-ZRTUS6WD.js";
10
10
  import {
11
11
  readJsonSafe
12
12
  } from "./chunk-T5I4PKOQ.js";
13
13
  import {
14
14
  isRecord,
15
15
  isValidApiKey
16
- } from "./chunk-TRDHHF3A.js";
16
+ } from "./chunk-W744DTUT.js";
17
17
 
18
18
  // src/shared-mcp-key.ts
19
19
  var asRecord = (value) => value !== null && typeof value === "object" && !Array.isArray(value) ? value : void 0;
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  ensureCodexTrustsPusharyHooks
3
- } from "./chunk-NVV3YUTX.js";
3
+ } from "./chunk-YOSATSUD.js";
4
4
  import {
5
5
  hermesReceiptPaths,
6
6
  hermesSetupPredatesThePluginFolder,
7
7
  installHermesPlugin,
8
8
  refreshHermesPluginFiles,
9
9
  shippedHermesPlugin
10
- } from "./chunk-5HKU4VUL.js";
10
+ } from "./chunk-ZWUVJ3DV.js";
11
11
  import {
12
12
  fxIgnoresInstructionsFile,
13
13
  fxInstructionsBody,
@@ -16,7 +16,7 @@ import {
16
16
  macAppFxBridge,
17
17
  refreshClineKey,
18
18
  switchFxHttpEntryToBridge
19
- } from "./chunk-K5WTTEIQ.js";
19
+ } from "./chunk-5NHWNILG.js";
20
20
  import {
21
21
  OPENCODE_HOOK_BINARY,
22
22
  agentHookOwner,
@@ -28,16 +28,16 @@ import {
28
28
  openCodePluginDir,
29
29
  openCodeWired,
30
30
  withOpenCodeAskRules
31
- } from "./chunk-AGXOTZID.js";
31
+ } from "./chunk-INKDRMSK.js";
32
32
  import {
33
33
  detectClaudeVersion
34
- } from "./chunk-CXIYGD33.js";
34
+ } from "./chunk-YQGPBLIT.js";
35
35
  import {
36
36
  addCompatibleHooks,
37
37
  compatibleConfigFile,
38
38
  compatibleInstructionsFile,
39
39
  hasCompatibleHooks
40
- } from "./chunk-YZESBU7F.js";
40
+ } from "./chunk-HHZSB6KL.js";
41
41
  import {
42
42
  GEMINI_HOOK_BINARY,
43
43
  addGeminiHooks,
@@ -49,7 +49,7 @@ import {
49
49
  geminiWired,
50
50
  hasGeminiHooks,
51
51
  planHooks
52
- } from "./chunk-COXNQUDP.js";
52
+ } from "./chunk-3GFJ7CXQ.js";
53
53
  import {
54
54
  CLAUDE_HOOK_BINARY,
55
55
  CLAUDE_HOOK_EVENTS,
@@ -95,13 +95,13 @@ import {
95
95
  renderAgentInstructions,
96
96
  supportedClaudeEvents,
97
97
  vscodePluginMcp
98
- } from "./chunk-CBLFIWPI.js";
98
+ } from "./chunk-ZRTUS6WD.js";
99
99
  import {
100
100
  formatVersion,
101
101
  hookCommandsUseBareNames,
102
102
  resolveGlobalBinDir,
103
103
  resolveGlobalBinary
104
- } from "./chunk-KOZBVXXC.js";
104
+ } from "./chunk-ODXZPMKN.js";
105
105
  import {
106
106
  readJsonSafe,
107
107
  writeFileAtomic,
@@ -111,7 +111,7 @@ import {
111
111
  HOOK_COMPATIBLE_PROFILES,
112
112
  isCompatibleAgentType,
113
113
  isRecord
114
- } from "./chunk-TRDHHF3A.js";
114
+ } from "./chunk-W744DTUT.js";
115
115
 
116
116
  // src/reapply.ts
117
117
  import { dirname, join } from "path";
@@ -3,24 +3,24 @@ import {
3
3
  expectedLaunchCapabilities,
4
4
  hasSpawnProvider,
5
5
  resolveControlPolicy
6
- } from "./chunk-SSBETUYZ.js";
6
+ } from "./chunk-W4MZBZU3.js";
7
7
  import {
8
8
  daemonHasRemoteProof,
9
9
  daemonServiceManagerAvailable,
10
10
  hasDaemonServiceDefinition,
11
11
  readDaemonNeedsLogin,
12
12
  readDaemonStatus
13
- } from "./chunk-EISUEJDT.js";
13
+ } from "./chunk-WFHUECGB.js";
14
14
  import {
15
15
  getMachineId
16
- } from "./chunk-TZYVXTLN.js";
16
+ } from "./chunk-6FR5ZYMS.js";
17
17
  import {
18
18
  readControlMode,
19
19
  readKeySource
20
- } from "./chunk-YZ7V2LVG.js";
20
+ } from "./chunk-CPBS6LS3.js";
21
21
  import {
22
22
  getBaseUrl
23
- } from "./chunk-R3RTISDD.js";
23
+ } from "./chunk-MZX35RFX.js";
24
24
  import {
25
25
  getPackageVersion
26
26
  } from "./chunk-ZVU6WMMU.js";
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  CODEX_HOOK_STATUS
3
- } from "./chunk-NVV3YUTX.js";
3
+ } from "./chunk-YOSATSUD.js";
4
4
  import {
5
5
  retryAgentCommand
6
- } from "./chunk-XBH6OKHD.js";
6
+ } from "./chunk-EDNCFLR7.js";
7
7
  import {
8
8
  NPX_LATEST_COMMAND
9
- } from "./chunk-PJSFKKZ5.js";
9
+ } from "./chunk-7VRL6XYM.js";
10
10
 
11
11
  // src/setup/codex-trust.ts
12
12
  var CODEX_TRUST_TELEMETRY = {