pushary 1.9.239 → 1.9.240
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/dist/{api-TGQFNSNE.js → api-S3HQL4CV.js} +11 -11
- package/dist/bin/pushary-audit.js +3 -3
- package/dist/bin/pushary-bell-hook.js +28 -28
- package/dist/bin/pushary-bell.js +12 -12
- package/dist/bin/pushary-calls.js +15 -15
- package/dist/bin/pushary-claude.js +26 -26
- package/dist/bin/pushary-clean.js +40 -40
- package/dist/bin/pushary-codex-bridge.js +23 -23
- package/dist/bin/pushary-codex-hook.js +34 -34
- package/dist/bin/pushary-codex-session.js +8 -8
- package/dist/bin/pushary-codex.js +16 -16
- package/dist/bin/pushary-connect.js +35 -35
- package/dist/bin/pushary-cowork.js +5 -5
- package/dist/bin/pushary-daemon.js +46 -46
- package/dist/bin/pushary-disconnect.js +30 -30
- package/dist/bin/pushary-display-hook.js +10 -9
- package/dist/bin/pushary-doctor.js +48 -48
- package/dist/bin/pushary-elicitation-hook.js +27 -27
- package/dist/bin/pushary-gemini-bridge.js +18 -18
- package/dist/bin/pushary-gemini-hook.js +31 -31
- package/dist/bin/pushary-hook.js +35 -35
- package/dist/bin/pushary-login.js +23 -23
- package/dist/bin/pushary-logout.js +31 -31
- package/dist/bin/pushary-mcp.js +12 -12
- package/dist/bin/pushary-mode.js +16 -16
- package/dist/bin/pushary-notification-hook.js +27 -27
- package/dist/bin/pushary-opencode-bridge.js +22 -22
- package/dist/bin/pushary-opencode-hook.js +32 -32
- package/dist/bin/pushary-permission-denied-hook.js +34 -34
- package/dist/bin/pushary-permission-hook.js +35 -35
- package/dist/bin/pushary-post-hook.js +28 -28
- package/dist/bin/pushary-prompt-hook.js +27 -27
- package/dist/bin/pushary-session-end-hook.js +27 -27
- package/dist/bin/pushary-session-start-hook.js +39 -39
- package/dist/bin/pushary-sessions.js +12 -12
- package/dist/bin/pushary-setup.js +140 -173
- package/dist/bin/pushary-stats.js +5 -5
- package/dist/bin/pushary-status.js +41 -37
- package/dist/bin/pushary-stop-hook.js +27 -27
- package/dist/bin/pushary-stopfailure-hook.js +27 -27
- package/dist/bin/pushary-suggestions.js +16 -16
- package/dist/bin/pushary-transcript-register.js +17 -17
- package/dist/bin/pushary-transcripts.js +26 -26
- package/dist/bin/pushary-upgrade.js +47 -47
- package/dist/bin/pushary-wait.js +16 -16
- package/dist/bin/pushary.js +7 -7
- package/dist/{chunk-M5DTFZNE.js → chunk-2FKAQDIY.js} +2 -2
- package/dist/{chunk-M45LA6SN.js → chunk-3KR7IXGP.js} +4 -4
- package/dist/{chunk-F3RLSCGY.js → chunk-3RHUT4CT.js} +5 -5
- package/dist/{chunk-LB4TIIP6.js → chunk-3VGW6MMH.js} +4 -4
- package/dist/{chunk-O6QSYCV7.js → chunk-47PF7UUS.js} +3 -3
- package/dist/{chunk-2QKCDW7C.js → chunk-4ALCCCOW.js} +34 -16
- package/dist/{chunk-AXCHFAM2.js → chunk-4KA5FPCU.js} +2 -2
- package/dist/{chunk-WLKHQOWW.js → chunk-4SERWSEJ.js} +8 -8
- package/dist/{chunk-F7UH6EIK.js → chunk-54FAMVFU.js} +1 -1
- package/dist/{chunk-P6WHHGDL.js → chunk-5JEWS5WP.js} +1 -1
- package/dist/{chunk-WK6FLRWC.js → chunk-5MTDC25A.js} +6 -6
- package/dist/{chunk-TZ2JD5R2.js → chunk-5ONH6JSZ.js} +1 -1
- package/dist/{chunk-7LDSPVKG.js → chunk-6HCARNSZ.js} +23 -3
- package/dist/{chunk-QXPBSQAJ.js → chunk-6MK3OFFQ.js} +12 -12
- package/dist/{chunk-YXNVJ6QV.js → chunk-6O4LOD7E.js} +1 -1
- package/dist/{chunk-CUKCOSSW.js → chunk-6T3JNLXH.js} +1 -1
- package/dist/{chunk-AS5IBOCJ.js → chunk-7HX3GQ3J.js} +1 -1
- package/dist/{chunk-TSQUSQYM.js → chunk-AZ7I6F6U.js} +2 -2
- package/dist/{chunk-7DK5D7K5.js → chunk-B4U25UYA.js} +3 -3
- package/dist/{chunk-22KXKP3P.js → chunk-B7LTTHPP.js} +2 -2
- package/dist/{chunk-WO3XKRTP.js → chunk-B7TUAYY4.js} +7 -7
- package/dist/{chunk-OM4WDT5Q.js → chunk-BFFE3XUB.js} +11 -5
- package/dist/{chunk-YJ6PCUUZ.js → chunk-BWJ5XWOY.js} +1 -1
- package/dist/{chunk-U6UOY645.js → chunk-BXIW4PYY.js} +1 -1
- package/dist/{chunk-JSRQCQI4.js → chunk-C2G6EI42.js} +5 -5
- package/dist/{chunk-YMVC3ADR.js → chunk-CBNSLSTN.js} +16 -16
- package/dist/{chunk-6AT6CW76.js → chunk-CDP47IC4.js} +1 -1
- package/dist/{chunk-JUE3F3SH.js → chunk-CGNHFWTM.js} +10 -6
- package/dist/{chunk-CYRFUNSV.js → chunk-CP7FDXDR.js} +4 -4
- package/dist/{chunk-CM2CXLMV.js → chunk-DGF63IWR.js} +1 -1
- package/dist/{chunk-PPW3FH2O.js → chunk-EJIVYRYV.js} +6 -6
- package/dist/{chunk-2NFLU35D.js → chunk-EOIWK4T3.js} +2 -2
- package/dist/{chunk-PB2J2OH6.js → chunk-FIW3N3OO.js} +2 -2
- package/dist/{chunk-LAZTGJCP.js → chunk-FN6K5DJE.js} +1 -1
- package/dist/{chunk-VFFTSN5A.js → chunk-G7N3AMF2.js} +4 -4
- package/dist/{chunk-EW6MOHU7.js → chunk-GRDGIN5F.js} +1 -1
- package/dist/{chunk-D5IDQEUV.js → chunk-GUZHMUPZ.js} +2 -9
- package/dist/{chunk-KXIKVN4W.js → chunk-HYCSVBZU.js} +5 -5
- package/dist/{chunk-3OTL7RDO.js → chunk-I2PDVTLE.js} +14 -7
- package/dist/{chunk-MQ7TQFAM.js → chunk-IIHJRQUH.js} +4 -4
- package/dist/{chunk-ODQRIHHZ.js → chunk-IUGLAPOI.js} +7 -3
- package/dist/{chunk-7JVDYUXV.js → chunk-IVVAUS4X.js} +4 -4
- package/dist/{chunk-GHK2D2AY.js → chunk-JNGQTIM4.js} +2 -2
- package/dist/{chunk-MD35ZRMK.js → chunk-JVVVKMHW.js} +1 -1
- package/dist/{chunk-4XOSBQS3.js → chunk-KIY2LDOS.js} +1 -1
- package/dist/{chunk-PMZLFGA4.js → chunk-KNR4GPWC.js} +1 -1
- package/dist/{chunk-PWLZRTPN.js → chunk-MGGUU2HK.js} +5 -5
- package/dist/{chunk-XMCHE2KX.js → chunk-MN52HESI.js} +2 -2
- package/dist/{chunk-B2UVKWAC.js → chunk-MRRFHM5W.js} +3 -3
- package/dist/{chunk-QCWKDVGM.js → chunk-MUJQEBEI.js} +3 -3
- package/dist/{chunk-XULGWSCM.js → chunk-N27CCH7E.js} +3 -24
- package/dist/{chunk-OKSLHMMV.js → chunk-NSTSKANY.js} +1 -1
- package/dist/{chunk-ARDB6TVA.js → chunk-OCX3VPL7.js} +14 -12
- package/dist/{chunk-2CNBP34Z.js → chunk-OKAFHEJQ.js} +3 -3
- package/dist/{chunk-BCFJAUVD.js → chunk-ON7GUC77.js} +11 -11
- package/dist/{chunk-KEC6WMMH.js → chunk-OQMYK75R.js} +1 -1
- package/dist/{chunk-K3KDWSGN.js → chunk-OSQPNWK2.js} +3 -3
- package/dist/{chunk-775CXETC.js → chunk-PBAX5ZTC.js} +3 -3
- package/dist/{chunk-XFVILXWT.js → chunk-PIF4FJBM.js} +4 -4
- package/dist/{chunk-NIL4UMQO.js → chunk-QHZUGUXM.js} +4 -4
- package/dist/{chunk-FETLPBX4.js → chunk-R3KWJHV5.js} +5 -5
- package/dist/{chunk-P3M2TEIB.js → chunk-RRDNCZ5B.js} +1 -1
- package/dist/{chunk-K5QXVI6H.js → chunk-S5NZYFIW.js} +5 -5
- package/dist/{chunk-34WXXHZK.js → chunk-SFE3KYTV.js} +1 -1
- package/dist/{chunk-HFTEGMJQ.js → chunk-SHJTV4M2.js} +7 -7
- package/dist/{chunk-6YHIIZCD.js → chunk-SR3IJPFT.js} +5 -5
- package/dist/{chunk-HCUODMK4.js → chunk-T7BENAXJ.js} +2 -2
- package/dist/{chunk-HUB2GUFP.js → chunk-UPLB3UAG.js} +5 -5
- package/dist/{chunk-TBFF32OX.js → chunk-UZDOP52C.js} +3 -3
- package/dist/{chunk-OBCDZUDW.js → chunk-VBXEKGOD.js} +1 -1
- package/dist/{chunk-Y4FDXCBJ.js → chunk-VGPLLTWD.js} +1 -1
- package/dist/{chunk-DBYMWNEA.js → chunk-VWYNFCZZ.js} +9 -9
- package/dist/{chunk-43EGMRVL.js → chunk-W5RHKVDB.js} +10 -10
- package/dist/{chunk-NYW3IHWT.js → chunk-WSVJH327.js} +2 -2
- package/dist/{chunk-CU53UYPR.js → chunk-WVKLSWNF.js} +1 -1
- package/dist/{chunk-UOPOVQ2P.js → chunk-XNF5DVAF.js} +1 -3
- package/dist/{chunk-QFCZHHXE.js → chunk-YBEZ373R.js} +5 -5
- package/dist/{chunk-ZDI2GOT7.js → chunk-YMNUS2OX.js} +2 -2
- package/dist/{chunk-ENMJP2QR.js → chunk-Z3GHXUCO.js} +7 -5
- package/dist/{chunk-35IKDC3S.js → chunk-Z443YMGX.js} +5 -5
- package/dist/{chunk-URA3EVIO.js → chunk-ZOCOTPP5.js} +2 -2
- package/dist/{chunk-O2RFCZXX.js → chunk-ZVMQ5WJM.js} +1 -1
- package/dist/{codex-app-cards-switch-G66CLZF2.js → codex-app-cards-switch-JY256N6Q.js} +11 -11
- package/dist/{codex-card-routing-L564JCTO.js → codex-card-routing-GJFKRHFN.js} +2 -2
- package/dist/{codex-desktop-launch-WKHFUAT7.js → codex-desktop-launch-KADUT764.js} +3 -3
- package/dist/{codex-session-launch-EBEKNB5T.js → codex-session-launch-5UQLTCD6.js} +20 -20
- package/dist/{config-F46PJ6G2.js → config-BCLQDBDL.js} +3 -3
- package/dist/{global-upgrade-XK32FCB7.js → global-upgrade-GF52LKRB.js} +9 -9
- package/dist/{identity-MGMANSPJ.js → identity-KJUPRF7O.js} +4 -4
- package/dist/{live-capabilities-WZWQK6TQ.js → live-capabilities-3WYHLMMU.js} +4 -4
- package/dist/{paths-I3B3AESI.js → paths-M2JGTCLR.js} +3 -3
- package/dist/{reapply-FSHLY63O.js → reapply-UEQZ26JC.js} +34 -34
- package/dist/src/index.js +33 -33
- package/dist/{upgrade-lock-4TOOLEEM.js → upgrade-lock-EGMKQLIM.js} +4 -4
- package/dist/{usage-AMBJJOGG.js → usage-DN7WLHLX.js} +3 -3
- package/package.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
withUpgradeLock
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
4
|
+
} from "../chunk-5MTDC25A.js";
|
|
5
|
+
import "../chunk-YMNUS2OX.js";
|
|
6
6
|
import {
|
|
7
7
|
browserEntryUrl,
|
|
8
8
|
cancelLogin,
|
|
@@ -14,7 +14,7 @@ import {
|
|
|
14
14
|
runBrowserLogin,
|
|
15
15
|
startLogin,
|
|
16
16
|
waitForLogin
|
|
17
|
-
} from "../chunk-
|
|
17
|
+
} from "../chunk-4KA5FPCU.js";
|
|
18
18
|
import {
|
|
19
19
|
INSTALL_NODE_STEP,
|
|
20
20
|
NPM_FILE_IN_USE_STEP,
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
renderCommandSurface,
|
|
29
29
|
teamOfferLines,
|
|
30
30
|
unverifiedKeyClosingReason
|
|
31
|
-
} from "../chunk-
|
|
31
|
+
} from "../chunk-R3KWJHV5.js";
|
|
32
32
|
import {
|
|
33
33
|
WRONG_ACCOUNT_HINT,
|
|
34
34
|
canAskAtTheTerminal,
|
|
@@ -51,32 +51,32 @@ import {
|
|
|
51
51
|
someoneIsAtTheTerminal,
|
|
52
52
|
switchBackToTheShellKeyLine,
|
|
53
53
|
wrongAccountHintPlacement
|
|
54
|
-
} from "../chunk-
|
|
54
|
+
} from "../chunk-SR3IJPFT.js";
|
|
55
55
|
import {
|
|
56
56
|
instructionsChannelFor,
|
|
57
57
|
pairingComputerOf,
|
|
58
58
|
planPhoneCheck
|
|
59
|
-
} from "../chunk-
|
|
59
|
+
} from "../chunk-RRDNCZ5B.js";
|
|
60
60
|
import {
|
|
61
61
|
coworkOutput,
|
|
62
62
|
coworkSelection
|
|
63
|
-
} from "../chunk-
|
|
63
|
+
} from "../chunk-MUJQEBEI.js";
|
|
64
64
|
import {
|
|
65
65
|
canOpenBrowser,
|
|
66
66
|
openInBrowser
|
|
67
67
|
} from "../chunk-PUZZELE6.js";
|
|
68
68
|
import {
|
|
69
69
|
readCodexHooksOnDisk
|
|
70
|
-
} from "../chunk-
|
|
70
|
+
} from "../chunk-VWYNFCZZ.js";
|
|
71
71
|
import {
|
|
72
72
|
macAppHistoryDecision,
|
|
73
73
|
nativeBridgeAccount
|
|
74
74
|
} from "../chunk-TWWOQKXK.js";
|
|
75
|
-
import "../chunk-
|
|
75
|
+
import "../chunk-WSVJH327.js";
|
|
76
76
|
import {
|
|
77
77
|
clearDeclinedAgent,
|
|
78
78
|
declinedAgentForSetupChoice
|
|
79
|
-
} from "../chunk-
|
|
79
|
+
} from "../chunk-JNGQTIM4.js";
|
|
80
80
|
import {
|
|
81
81
|
OPENCLAW_RESTART_NOTE,
|
|
82
82
|
describeOpenClawInstallFailure,
|
|
@@ -84,7 +84,7 @@ import {
|
|
|
84
84
|
gateHermesShell,
|
|
85
85
|
readHermesShellGate,
|
|
86
86
|
saveSetupFailure
|
|
87
|
-
} from "../chunk-
|
|
87
|
+
} from "../chunk-Z3GHXUCO.js";
|
|
88
88
|
import {
|
|
89
89
|
CODEX_NEEDS_A_NEWER_VERSION,
|
|
90
90
|
CODEX_SETTINGS_STOP_A_HOOK,
|
|
@@ -100,14 +100,14 @@ import {
|
|
|
100
100
|
describeHermesState,
|
|
101
101
|
hermesGateShellCommand,
|
|
102
102
|
needsCodexTrustStep
|
|
103
|
-
} from "../chunk-
|
|
103
|
+
} from "../chunk-3KR7IXGP.js";
|
|
104
104
|
import {
|
|
105
105
|
describeWaitLadder
|
|
106
106
|
} from "../chunk-CVWG2N3Y.js";
|
|
107
107
|
import {
|
|
108
108
|
writeJsonError,
|
|
109
109
|
writeStdoutFully
|
|
110
|
-
} from "../chunk-
|
|
110
|
+
} from "../chunk-5ONH6JSZ.js";
|
|
111
111
|
import {
|
|
112
112
|
EXIT_ABORTED,
|
|
113
113
|
EXIT_TERMINATED,
|
|
@@ -137,7 +137,7 @@ import {
|
|
|
137
137
|
startPairing,
|
|
138
138
|
waitForYourPhone,
|
|
139
139
|
writeStatusLine
|
|
140
|
-
} from "../chunk-
|
|
140
|
+
} from "../chunk-OCX3VPL7.js";
|
|
141
141
|
import {
|
|
142
142
|
generateKeypair,
|
|
143
143
|
publicKeyFingerprint
|
|
@@ -149,7 +149,7 @@ import {
|
|
|
149
149
|
roundTripEvidence,
|
|
150
150
|
roundTripWasAnswered,
|
|
151
151
|
verifyRoundTrip
|
|
152
|
-
} from "../chunk-
|
|
152
|
+
} from "../chunk-4ALCCCOW.js";
|
|
153
153
|
import {
|
|
154
154
|
keepLinuxDaemonAfterLogout,
|
|
155
155
|
lingerReportOf
|
|
@@ -157,13 +157,13 @@ import {
|
|
|
157
157
|
import {
|
|
158
158
|
readManagedControlEvidence,
|
|
159
159
|
waitForMachineReadiness
|
|
160
|
-
} from "../chunk-
|
|
160
|
+
} from "../chunk-UPLB3UAG.js";
|
|
161
161
|
import {
|
|
162
162
|
ensureCodexTrustsPusharyHooks,
|
|
163
163
|
hermesHistoryHelperRecordPath,
|
|
164
164
|
hermesHistoryNeedsTheCliHelper,
|
|
165
165
|
recordInstalledHermesHistoryHelper
|
|
166
|
-
} from "../chunk-
|
|
166
|
+
} from "../chunk-OKAFHEJQ.js";
|
|
167
167
|
import {
|
|
168
168
|
scheduleWithTimer
|
|
169
169
|
} from "../chunk-AVFPHV4N.js";
|
|
@@ -171,10 +171,10 @@ import {
|
|
|
171
171
|
describeSetupSideEffects,
|
|
172
172
|
installAgentSkill,
|
|
173
173
|
installSkillViaSkillsCli
|
|
174
|
-
} from "../chunk-
|
|
174
|
+
} from "../chunk-XNF5DVAF.js";
|
|
175
175
|
import {
|
|
176
176
|
codexEngineBehindLauncher
|
|
177
|
-
} from "../chunk-
|
|
177
|
+
} from "../chunk-PIF4FJBM.js";
|
|
178
178
|
import "../chunk-XCEN33UP.js";
|
|
179
179
|
import {
|
|
180
180
|
CODEX_ENGINE_DIRECTORY,
|
|
@@ -191,7 +191,7 @@ import {
|
|
|
191
191
|
soleGateLeftAloneFor,
|
|
192
192
|
soleGateReceipt,
|
|
193
193
|
soleGateReceiptFile
|
|
194
|
-
} from "../chunk-
|
|
194
|
+
} from "../chunk-3VGW6MMH.js";
|
|
195
195
|
import {
|
|
196
196
|
describeDetection,
|
|
197
197
|
detectAllAgents,
|
|
@@ -201,14 +201,14 @@ import {
|
|
|
201
201
|
registerPluginLocation,
|
|
202
202
|
shortenHome,
|
|
203
203
|
vscodeSettingsTargets
|
|
204
|
-
} from "../chunk-
|
|
204
|
+
} from "../chunk-MGGUU2HK.js";
|
|
205
205
|
import {
|
|
206
206
|
revokeOwnKey
|
|
207
207
|
} from "../chunk-OYIN77HO.js";
|
|
208
208
|
import {
|
|
209
209
|
mcpServerBearer,
|
|
210
210
|
readMacAppAgentKey
|
|
211
|
-
} from "../chunk-
|
|
211
|
+
} from "../chunk-IVVAUS4X.js";
|
|
212
212
|
import {
|
|
213
213
|
HERMES_CONFIG_FILE,
|
|
214
214
|
HERMES_GATE_TOOLS_KEY,
|
|
@@ -227,7 +227,7 @@ import {
|
|
|
227
227
|
routesHermesQuestions,
|
|
228
228
|
runsAnOlderPlugin,
|
|
229
229
|
shippedHermesPlugin
|
|
230
|
-
} from "../chunk-
|
|
230
|
+
} from "../chunk-BFFE3XUB.js";
|
|
231
231
|
import {
|
|
232
232
|
setHumanStream
|
|
233
233
|
} from "../chunk-QCGNGEGE.js";
|
|
@@ -235,7 +235,7 @@ import {
|
|
|
235
235
|
findOpenClawLauncher,
|
|
236
236
|
isOpenClawWired,
|
|
237
237
|
openClawPathsNow
|
|
238
|
-
} from "../chunk-
|
|
238
|
+
} from "../chunk-6HCARNSZ.js";
|
|
239
239
|
import {
|
|
240
240
|
FX_PICKS_UP_CONFIGURATION,
|
|
241
241
|
FX_PUSHARY_TOOLS_RULE,
|
|
@@ -252,7 +252,7 @@ import {
|
|
|
252
252
|
readFxProfileForSetup,
|
|
253
253
|
withFxPusharyServer,
|
|
254
254
|
writeFxProfile
|
|
255
|
-
} from "../chunk-
|
|
255
|
+
} from "../chunk-S5NZYFIW.js";
|
|
256
256
|
import {
|
|
257
257
|
AgentConfigError,
|
|
258
258
|
afterAgentFailureNote,
|
|
@@ -265,10 +265,10 @@ import {
|
|
|
265
265
|
retryAgentCommand,
|
|
266
266
|
writeSetupConfigFile,
|
|
267
267
|
writeSetupConfigJson
|
|
268
|
-
} from "../chunk-
|
|
268
|
+
} from "../chunk-PBAX5ZTC.js";
|
|
269
269
|
import {
|
|
270
270
|
MCP_BRIDGE_BINARY
|
|
271
|
-
} from "../chunk-
|
|
271
|
+
} from "../chunk-QHZUGUXM.js";
|
|
272
272
|
import {
|
|
273
273
|
OPENCODE_HOOK_BINARY,
|
|
274
274
|
addOpenCodeMcpServer,
|
|
@@ -287,12 +287,12 @@ import {
|
|
|
287
287
|
openCodePluginFile,
|
|
288
288
|
openCodeWired,
|
|
289
289
|
withOpenCodeAskRules
|
|
290
|
-
} from "../chunk-
|
|
291
|
-
import "../chunk-
|
|
292
|
-
import "../chunk-
|
|
290
|
+
} from "../chunk-SHJTV4M2.js";
|
|
291
|
+
import "../chunk-KIY2LDOS.js";
|
|
292
|
+
import "../chunk-JVVVKMHW.js";
|
|
293
293
|
import {
|
|
294
294
|
keyScopeOf
|
|
295
|
-
} from "../chunk-
|
|
295
|
+
} from "../chunk-B7LTTHPP.js";
|
|
296
296
|
import {
|
|
297
297
|
ansiPainter,
|
|
298
298
|
ciMarker,
|
|
@@ -301,7 +301,7 @@ import {
|
|
|
301
301
|
describeError,
|
|
302
302
|
isCI,
|
|
303
303
|
useColor
|
|
304
|
-
} from "../chunk-
|
|
304
|
+
} from "../chunk-VBXEKGOD.js";
|
|
305
305
|
import {
|
|
306
306
|
checkCodexInstall,
|
|
307
307
|
describeMissingControlPrerequisite,
|
|
@@ -314,16 +314,16 @@ import {
|
|
|
314
314
|
nodeCodexInstallProbe,
|
|
315
315
|
phoneStartIsRequired,
|
|
316
316
|
resolveControlPolicy
|
|
317
|
-
} from "../chunk-
|
|
317
|
+
} from "../chunk-OSQPNWK2.js";
|
|
318
318
|
import {
|
|
319
319
|
detectClaudeVersion
|
|
320
|
-
} from "../chunk-
|
|
320
|
+
} from "../chunk-5JEWS5WP.js";
|
|
321
321
|
import "../chunk-TCE3J44Z.js";
|
|
322
322
|
import {
|
|
323
323
|
describeAutoUpdateAnnouncement,
|
|
324
324
|
takeAutoUpdateAnnouncement
|
|
325
|
-
} from "../chunk-
|
|
326
|
-
import "../chunk-
|
|
325
|
+
} from "../chunk-FIW3N3OO.js";
|
|
326
|
+
import "../chunk-MRRFHM5W.js";
|
|
327
327
|
import "../chunk-WHB622LP.js";
|
|
328
328
|
import {
|
|
329
329
|
addCompatibleHooks,
|
|
@@ -338,7 +338,7 @@ import {
|
|
|
338
338
|
compatibleRecord,
|
|
339
339
|
compatibleTargetPaths,
|
|
340
340
|
hasCompatibleHooks
|
|
341
|
-
} from "../chunk-
|
|
341
|
+
} from "../chunk-3RHUT4CT.js";
|
|
342
342
|
import {
|
|
343
343
|
DAEMON_COLD_START_TIMEOUT_MS,
|
|
344
344
|
clearDaemonNeedsLogin,
|
|
@@ -357,7 +357,7 @@ import {
|
|
|
357
357
|
stopDaemonService,
|
|
358
358
|
versionManagerOf,
|
|
359
359
|
waitForDaemonRemoteProof
|
|
360
|
-
} from "../chunk-
|
|
360
|
+
} from "../chunk-I2PDVTLE.js";
|
|
361
361
|
import {
|
|
362
362
|
GEMINI_HOOK_BINARY,
|
|
363
363
|
GEMINI_HOOK_EVENTS,
|
|
@@ -373,41 +373,40 @@ import {
|
|
|
373
373
|
geminiWired,
|
|
374
374
|
planHooks,
|
|
375
375
|
pusharyHookExecutable
|
|
376
|
-
} from "../chunk-
|
|
376
|
+
} from "../chunk-G7N3AMF2.js";
|
|
377
377
|
import {
|
|
378
378
|
reportEvent
|
|
379
|
-
} from "../chunk-
|
|
380
|
-
import "../chunk-
|
|
379
|
+
} from "../chunk-ON7GUC77.js";
|
|
380
|
+
import "../chunk-7HX3GQ3J.js";
|
|
381
381
|
import {
|
|
382
382
|
AGENT_CHOICES,
|
|
383
383
|
effectiveAgentSelection,
|
|
384
384
|
effectiveControlMode,
|
|
385
385
|
effectiveVerify,
|
|
386
386
|
parseSetupOptions
|
|
387
|
-
} from "../chunk-
|
|
388
|
-
import "../chunk-
|
|
387
|
+
} from "../chunk-FN6K5DJE.js";
|
|
388
|
+
import "../chunk-NSTSKANY.js";
|
|
389
389
|
import "../chunk-BZIBNSQE.js";
|
|
390
390
|
import {
|
|
391
391
|
transcriptPreferenceForSetup
|
|
392
|
-
} from "../chunk-
|
|
392
|
+
} from "../chunk-BWJ5XWOY.js";
|
|
393
393
|
import "../chunk-P6DUWKAO.js";
|
|
394
394
|
import "../chunk-3PSNUHC5.js";
|
|
395
|
-
import "../chunk-
|
|
396
|
-
import "../chunk-
|
|
395
|
+
import "../chunk-EJIVYRYV.js";
|
|
396
|
+
import "../chunk-6T3JNLXH.js";
|
|
397
397
|
import "../chunk-POFBE6ZY.js";
|
|
398
|
-
import "../chunk-
|
|
399
|
-
import "../chunk-
|
|
400
|
-
import "../chunk-
|
|
398
|
+
import "../chunk-Z443YMGX.js";
|
|
399
|
+
import "../chunk-KNR4GPWC.js";
|
|
400
|
+
import "../chunk-SFE3KYTV.js";
|
|
401
401
|
import {
|
|
402
402
|
checkApiKey,
|
|
403
403
|
describeKeyCheck,
|
|
404
404
|
samePusharyAccount
|
|
405
|
-
} from "../chunk-
|
|
406
|
-
import "../chunk-
|
|
407
|
-
import "../chunk-
|
|
405
|
+
} from "../chunk-IUGLAPOI.js";
|
|
406
|
+
import "../chunk-UZDOP52C.js";
|
|
407
|
+
import "../chunk-ZVMQ5WJM.js";
|
|
408
408
|
import {
|
|
409
409
|
KEY_FILE_MODE,
|
|
410
|
-
installClaudeAlias,
|
|
411
410
|
keyEnvFilePath,
|
|
412
411
|
newTerminalsUseSavedKey,
|
|
413
412
|
readConfigFileKey,
|
|
@@ -419,10 +418,10 @@ import {
|
|
|
419
418
|
resolveShellRc,
|
|
420
419
|
shellKeyWasReplaced,
|
|
421
420
|
writeKey
|
|
422
|
-
} from "../chunk-
|
|
421
|
+
} from "../chunk-N27CCH7E.js";
|
|
423
422
|
import {
|
|
424
423
|
reportedInstallSource
|
|
425
|
-
} from "../chunk-
|
|
424
|
+
} from "../chunk-EOIWK4T3.js";
|
|
426
425
|
import {
|
|
427
426
|
CLAUDE_CODE_PUSHARY_PERMISSION_RULES,
|
|
428
427
|
CLINE_AUTO_APPROVE_STEP,
|
|
@@ -431,7 +430,6 @@ import {
|
|
|
431
430
|
CODEX_INSTRUCTIONS_LABEL,
|
|
432
431
|
CODEX_RESTART_AFTER_TRANSPORT_CHANGE,
|
|
433
432
|
GEMINI_INSTRUCTIONS_LABEL,
|
|
434
|
-
SHARED_AGENTS_MD_LABEL,
|
|
435
433
|
addClaudeMcpServer,
|
|
436
434
|
addCodexHookTrust,
|
|
437
435
|
addCodexHooks,
|
|
@@ -479,12 +477,11 @@ import {
|
|
|
479
477
|
pusharyDir,
|
|
480
478
|
readCodexMcpAuth,
|
|
481
479
|
renderAgentInstructions,
|
|
482
|
-
renderProjectAgentInstructions,
|
|
483
480
|
updateClaudeMcpSnapshot,
|
|
484
481
|
vscodePluginDir,
|
|
485
482
|
vscodePluginMcp,
|
|
486
483
|
writeInstructionBlock
|
|
487
|
-
} from "../chunk-
|
|
484
|
+
} from "../chunk-GUZHMUPZ.js";
|
|
488
485
|
import {
|
|
489
486
|
compareVersion,
|
|
490
487
|
parseVersion
|
|
@@ -506,11 +503,11 @@ import {
|
|
|
506
503
|
runNpmInTerminal,
|
|
507
504
|
setupNeedsGlobalInstall,
|
|
508
505
|
setupWouldDowngrade
|
|
509
|
-
} from "../chunk-
|
|
506
|
+
} from "../chunk-IIHJRQUH.js";
|
|
510
507
|
import {
|
|
511
508
|
getBaseUrl,
|
|
512
509
|
readApiKey
|
|
513
|
-
} from "../chunk-
|
|
510
|
+
} from "../chunk-2FKAQDIY.js";
|
|
514
511
|
import {
|
|
515
512
|
UsageError
|
|
516
513
|
} from "../chunk-CINBAX5G.js";
|
|
@@ -522,7 +519,7 @@ import {
|
|
|
522
519
|
NPX_LATEST_COMMAND,
|
|
523
520
|
isInvocationOf,
|
|
524
521
|
renderCommandHelp
|
|
525
|
-
} from "../chunk-
|
|
522
|
+
} from "../chunk-DGF63IWR.js";
|
|
526
523
|
import {
|
|
527
524
|
EXIT
|
|
528
525
|
} from "../chunk-BG4HHB7E.js";
|
|
@@ -547,7 +544,7 @@ import {
|
|
|
547
544
|
isRecord,
|
|
548
545
|
isTimeoutAction,
|
|
549
546
|
isValidApiKey
|
|
550
|
-
} from "../chunk-
|
|
547
|
+
} from "../chunk-CGNHFWTM.js";
|
|
551
548
|
import "../chunk-MLKGABMK.js";
|
|
552
549
|
|
|
553
550
|
// bin/pushary-setup.ts
|
|
@@ -780,20 +777,20 @@ var keyRouter = (input2 = process.stdin, interrupt = interruptThisProcess) => {
|
|
|
780
777
|
};
|
|
781
778
|
|
|
782
779
|
// src/setup/restart-steps.ts
|
|
783
|
-
var
|
|
780
|
+
var OR_LIST = new Intl.ListFormat("en", { style: "long", type: "disjunction" });
|
|
784
781
|
var namesNeeding = (restarts, kind) => [...new Set(restarts.filter((restart) => restart.kind === kind).map((restart) => restart.agentName))];
|
|
785
782
|
var describeRestarts = (restarts) => {
|
|
786
783
|
const restart = namesNeeding(restarts, "restart");
|
|
787
784
|
const quit = namesNeeding(restarts, "quit-and-reopen");
|
|
788
785
|
return [
|
|
789
|
-
...restart.length > 0 ? [`
|
|
790
|
-
...quit.length > 0 ? [`
|
|
786
|
+
...restart.length > 0 ? [`If ${OR_LIST.format(restart)} is open, restart it to load Pushary.`] : [],
|
|
787
|
+
...quit.length > 0 ? [`If ${OR_LIST.format(quit)} is open, fully quit and reopen it. A Reload Window may not be enough.`] : []
|
|
791
788
|
];
|
|
792
789
|
};
|
|
793
790
|
|
|
794
791
|
// src/setup/agent-output.ts
|
|
795
792
|
var AGENTS_WHOSE_STEPS_ARE_THE_INSTRUCTIONS = /* @__PURE__ */ new Set(["custom"]);
|
|
796
|
-
var setupMayChangeHermesShellGate = (context) => context.agent === "hermes" && context.hermesShellGate
|
|
793
|
+
var setupMayChangeHermesShellGate = (context) => context.agent === "hermes" && (context.hermesShellGate === "apply" || context.hermesShellGate === "ask" && context.hermesShellGateMayAsk);
|
|
797
794
|
var agentOutputModeFor = (context) => {
|
|
798
795
|
if (context.verbose) return "every-step";
|
|
799
796
|
if (AGENTS_WHOSE_STEPS_ARE_THE_INSTRUCTIONS.has(context.agent)) return "every-step";
|
|
@@ -857,40 +854,48 @@ var CLEAR_PROGRESS_LINE = `\r${ERASE_TO_END_OF_LINE}`;
|
|
|
857
854
|
|
|
858
855
|
// src/setup/service-notice.ts
|
|
859
856
|
var PHONE_START_OPT_OUT = "Turn it off with --control off.";
|
|
860
|
-
var describeServiceInstall = (servicePresent) => servicePresent ?
|
|
857
|
+
var describeServiceInstall = (servicePresent) => servicePresent ? null : `Installing a background service so your phone can start agents. ${PHONE_START_OPT_OUT}`;
|
|
861
858
|
|
|
862
859
|
// src/setup/wait-guidance.ts
|
|
863
|
-
var UNAVAILABLE = "Approval settings unavailable. Run pushary wait before stepping away.";
|
|
864
860
|
var isPolicyRecord = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
|
|
865
861
|
var isWaitSeconds = (value) => typeof value === "number" && Number.isFinite(value) && value >= 0;
|
|
866
|
-
var
|
|
867
|
-
if (!isPolicyRecord(value) || !Array.isArray(value.policies)) return
|
|
868
|
-
if (value.modeOverride != null && !isApprovalMode(value.modeOverride)) return
|
|
862
|
+
var workspaceWaitDefaultOf = (value) => {
|
|
863
|
+
if (!isPolicyRecord(value) || !Array.isArray(value.policies)) return null;
|
|
864
|
+
if (value.modeOverride != null && !isApprovalMode(value.modeOverride)) return null;
|
|
869
865
|
const rule = value.policies.find((row) => isPolicyRecord(row) && row.tool === "*") ?? {
|
|
870
866
|
mode: value.defaultMode,
|
|
871
867
|
pushFirstSeconds: value.defaultPushFirstSeconds,
|
|
872
868
|
timeoutSeconds: value.defaultTimeoutSeconds,
|
|
873
869
|
timeoutAction: value.defaultTimeoutAction
|
|
874
870
|
};
|
|
875
|
-
if (!isPolicyRecord(rule) || !isApprovalMode(rule.mode) || !isTimeoutAction(rule.timeoutAction) || !isWaitSeconds(rule.pushFirstSeconds) || !isWaitSeconds(rule.timeoutSeconds)) return
|
|
871
|
+
if (!isPolicyRecord(rule) || !isApprovalMode(rule.mode) || !isTimeoutAction(rule.timeoutAction) || !isWaitSeconds(rule.pushFirstSeconds) || !isWaitSeconds(rule.timeoutSeconds)) return null;
|
|
876
872
|
const mode = value.modeOverride ?? rule.mode;
|
|
877
|
-
if (!isApprovalMode(mode)) return
|
|
873
|
+
if (!isApprovalMode(mode)) return null;
|
|
878
874
|
let behavior = describeWaitLadder({ tool: "*", mode, pushFirstSeconds: rule.pushFirstSeconds, timeoutSeconds: rule.timeoutSeconds, timeoutAction: rule.timeoutAction });
|
|
879
875
|
if (rule.timeoutSeconds === 0 && rule.timeoutAction === "approve") behavior = "auto-approve";
|
|
880
876
|
if (rule.timeoutSeconds === 0 && rule.timeoutAction === "deny") behavior = "auto-deny";
|
|
881
|
-
return
|
|
877
|
+
return { behavior, approvesUnanswered: rule.timeoutAction === "approve" && (mode === "push_only" || rule.timeoutSeconds === 0) };
|
|
882
878
|
};
|
|
883
|
-
var
|
|
879
|
+
var describeWorkspaceDefault = (waitDefault) => `Workspace default: ${waitDefault.behavior}. Agent, repository and tool rules can differ. Run pushary wait to inspect the rules.`;
|
|
880
|
+
var setupWaitWarning = (value) => {
|
|
881
|
+
const waitDefault = workspaceWaitDefaultOf(value);
|
|
882
|
+
return waitDefault?.approvesUnanswered === true ? describeWorkspaceDefault(waitDefault) : null;
|
|
883
|
+
};
|
|
884
|
+
var fetchWorkspacePolicy = async (apiKey) => {
|
|
884
885
|
try {
|
|
885
886
|
const response = await fetch(`${getBaseUrl()}/api/mcp/policy`, {
|
|
886
887
|
headers: { Authorization: `Bearer ${apiKey}` },
|
|
887
888
|
signal: AbortSignal.timeout(5e3)
|
|
888
889
|
});
|
|
889
|
-
return response.ok ?
|
|
890
|
+
return response.ok ? { ok: true, body: await response.json() } : { ok: false };
|
|
890
891
|
} catch {
|
|
891
|
-
return
|
|
892
|
+
return { ok: false };
|
|
892
893
|
}
|
|
893
894
|
};
|
|
895
|
+
var fetchSetupWaitWarning = async (apiKey) => {
|
|
896
|
+
const policy = await fetchWorkspacePolicy(apiKey);
|
|
897
|
+
return policy.ok ? setupWaitWarning(policy.body) : null;
|
|
898
|
+
};
|
|
894
899
|
|
|
895
900
|
// src/setup/codex-version.ts
|
|
896
901
|
import { dirname, join as join2 } from "path";
|
|
@@ -1307,6 +1312,7 @@ var waitForYourPhoneToSignIn = async (apiKey, signIn, keys, ui, deps = {}) => {
|
|
|
1307
1312
|
return await waitForYourPhone(apiKey, {
|
|
1308
1313
|
skip: keys.listenerFor(PHONE_WAIT_SKIP_KEY),
|
|
1309
1314
|
...deps.clock ? { clock: deps.clock } : {},
|
|
1315
|
+
...deps.followsABlankLine === true ? { followsABlankLine: true } : {},
|
|
1310
1316
|
intro: async () => {
|
|
1311
1317
|
await showTerminalPhoneSignIn(signIn, ui);
|
|
1312
1318
|
approval = approveThePhoneWhenItAsks(signIn, ui, {
|
|
@@ -1610,6 +1616,10 @@ var manualSteps = [];
|
|
|
1610
1616
|
var noteManual = (step) => {
|
|
1611
1617
|
manualSteps.push(step);
|
|
1612
1618
|
};
|
|
1619
|
+
var stepsShownOnTheirRow = [];
|
|
1620
|
+
var noteShownOnItsRow = (step) => {
|
|
1621
|
+
stepsShownOnTheirRow.push(step);
|
|
1622
|
+
};
|
|
1613
1623
|
var restartsNoted = [];
|
|
1614
1624
|
var manualStepsPrinted = 0;
|
|
1615
1625
|
var restartsPrinted = 0;
|
|
@@ -1730,7 +1740,7 @@ var checkForUpdates = async (current, markAnnounced) => {
|
|
|
1730
1740
|
var globalInstallReady = false;
|
|
1731
1741
|
var warnVersionManagerPin = (execPath) => {
|
|
1732
1742
|
const manager = versionManagerOf(execPath);
|
|
1733
|
-
if (manager) console.log(` ${
|
|
1743
|
+
if (manager) console.log(` ${dim(describeVersionManagerPin(manager))}`);
|
|
1734
1744
|
};
|
|
1735
1745
|
var reportLinger = (report) => {
|
|
1736
1746
|
if (!report) return;
|
|
@@ -1880,6 +1890,22 @@ var reportHermesShellGateWithoutOffer = (state, report, choice) => {
|
|
|
1880
1890
|
}
|
|
1881
1891
|
if (choice === "apply") console.log(` ${dim(`${report.label} (${report.detail}), so ${HERMES_GATE_TOOLS_KEY} was left as it is.`)}`);
|
|
1882
1892
|
};
|
|
1893
|
+
var HERMES_GATE_STATES_THAT_MAY_ASK = /* @__PURE__ */ new Set(["ungated", "unreadable"]);
|
|
1894
|
+
var accountEmailFromCheck = (check2) => check2.kind === "ok" ? check2.identity.accountEmail : null;
|
|
1895
|
+
var hermesShellGateMayAskNow = async () => {
|
|
1896
|
+
const launcher = findHermesLauncher();
|
|
1897
|
+
return launcher !== null && HERMES_GATE_STATES_THAT_MAY_ASK.has((await readHermesShellGate(launcher)).kind);
|
|
1898
|
+
};
|
|
1899
|
+
var withProgressLine = async (agent, read) => {
|
|
1900
|
+
const showsProgress = humanStream.isTTY === true;
|
|
1901
|
+
if (showsProgress) humanStream.write(progressLineFor(AGENT_NAMES[agent]));
|
|
1902
|
+
try {
|
|
1903
|
+
return await read();
|
|
1904
|
+
} finally {
|
|
1905
|
+
if (showsProgress) humanStream.write(CLEAR_PROGRESS_LINE);
|
|
1906
|
+
}
|
|
1907
|
+
};
|
|
1908
|
+
var contextThatNeverAsks = (context) => context.hermesShellGate === "ask" ? { ...context, hermesShellGate: "report" } : context;
|
|
1883
1909
|
var offerHermesShellGate = async (choice, receipts) => {
|
|
1884
1910
|
const launcher = findHermesLauncher();
|
|
1885
1911
|
if (!launcher) return;
|
|
@@ -1996,7 +2022,7 @@ var setupOpenClaw = async (_apiKey) => {
|
|
|
1996
2022
|
if (outcome.kind === "failed") {
|
|
1997
2023
|
const message = describeOpenClawInstallFailure(outcome.reason, outcome.detail);
|
|
1998
2024
|
console.log(` ${yellow("!")} ${message}`);
|
|
1999
|
-
|
|
2025
|
+
noteShownOnItsRow(message);
|
|
2000
2026
|
return "unchanged";
|
|
2001
2027
|
}
|
|
2002
2028
|
reportOpenClawInstall(outcome);
|
|
@@ -2506,13 +2532,10 @@ ${pluginLocationSnippet(VSCODE_PLUGIN_DIR)}`
|
|
|
2506
2532
|
};
|
|
2507
2533
|
var keySavedInConfigLine = (configPath) => `Your key is saved in ${configPath}, which is where hooks read it.`;
|
|
2508
2534
|
var saveApiKey = async (apiKey, origin, controlMode, transcriptSync, replacedKeyRecordWasHonoured) => {
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
transcriptsEnabled: transcriptSync,
|
|
2514
|
-
replacedKeyRecordWasHonoured
|
|
2515
|
-
});
|
|
2535
|
+
const result = writeKey(apiKey, origin, {
|
|
2536
|
+
controlMode,
|
|
2537
|
+
transcriptsEnabled: transcriptSync,
|
|
2538
|
+
replacedKeyRecordWasHonoured
|
|
2516
2539
|
});
|
|
2517
2540
|
if (!result) throw new Error("Could not save the API key");
|
|
2518
2541
|
if (result.configBackupPath) {
|
|
@@ -2550,7 +2573,7 @@ var saveApiKey = async (apiKey, origin, controlMode, transcriptSync, replacedKey
|
|
|
2550
2573
|
};
|
|
2551
2574
|
var FX_SETTINGS_RULES_SNIPPET = `"permission": { "${FX_PUSHARY_TOOLS_RULE}": "allow", "${FX_QUESTION_TOOL}": "deny" }`;
|
|
2552
2575
|
var FX_QUESTION_ROUTING_REPORTS = {
|
|
2553
|
-
"full-access": "fx
|
|
2576
|
+
"full-access": "fx is in full-access mode, so it may still ask some questions in the terminal. To send every question to your phone, run /permissions in fx and leave full-access mode.",
|
|
2554
2577
|
overridden: `A rule in ${fxSettings()} keeps fx's terminal question tool on, so fx can still ask there instead of through Pushary.`
|
|
2555
2578
|
};
|
|
2556
2579
|
var FX_QUESTION_SUMMARIES = {
|
|
@@ -2625,7 +2648,6 @@ var setupFx = async () => {
|
|
|
2625
2648
|
console.log(` ${dim("\u2022")} Questions: ${FX_QUESTION_SUMMARIES[settingsOutcome.kind === "written" ? settingsOutcome.questionRouting : "overridden"]}`);
|
|
2626
2649
|
console.log(` ${dim("\u2022")} fx cannot hand its own approval prompts to Pushary, so those still wait in the terminal`);
|
|
2627
2650
|
console.log(` ${dim(FX_PICKS_UP_CONFIGURATION)}`);
|
|
2628
|
-
noteManual(FX_PICKS_UP_CONFIGURATION);
|
|
2629
2651
|
return "configured";
|
|
2630
2652
|
};
|
|
2631
2653
|
var clineWired = () => inspectClineInstallation(clineMcpSettings(), void 0).configured;
|
|
@@ -2893,7 +2915,7 @@ var reportSoleGate = (profile, gate, claim) => {
|
|
|
2893
2915
|
return;
|
|
2894
2916
|
}
|
|
2895
2917
|
case "claimed":
|
|
2896
|
-
console.log(` ${yellow("!")}
|
|
2918
|
+
console.log(` ${yellow("!")} ${profile.label} now asks for approval only through Pushary, not in its own prompt. ${dim(`To undo: pushary disconnect ${profile.source}`)}`);
|
|
2897
2919
|
return;
|
|
2898
2920
|
case "already_sole_gate":
|
|
2899
2921
|
console.log(` ${dim("\u2022")} ${profile.label} already has ${soleGateSettingText(gate, gate.value)}, so Pushary is its only gate`);
|
|
@@ -3026,47 +3048,6 @@ var AGENT_SETUP = {
|
|
|
3026
3048
|
...COMPATIBLE_SETUP,
|
|
3027
3049
|
custom: setupCustom
|
|
3028
3050
|
};
|
|
3029
|
-
var PROJECT_INSTRUCTION_TARGETS = {
|
|
3030
|
-
claude_code: { file: "CLAUDE.md", label: "Claude Code" },
|
|
3031
|
-
codex: { file: "AGENTS.md", label: SHARED_AGENTS_MD_LABEL }
|
|
3032
|
-
};
|
|
3033
|
-
var offerProjectInstructions = async (agents, options) => {
|
|
3034
|
-
const targets = agents.map((agent) => PROJECT_INSTRUCTION_TARGETS[agent]).filter((target) => target !== void 0);
|
|
3035
|
-
if (targets.length === 0 || !process.stdout.isTTY || options.nonInteractive) return;
|
|
3036
|
-
console.log();
|
|
3037
|
-
const wanted = await confirm({
|
|
3038
|
-
message: `Add a Pushary section to ${targets.map((target) => target.file).join(" and ")} in this folder? It tells agents here to ask through Pushary.`,
|
|
3039
|
-
default: false
|
|
3040
|
-
});
|
|
3041
|
-
if (!wanted) return;
|
|
3042
|
-
for (const target of targets) {
|
|
3043
|
-
await spinner(`Writing managed block to ${join5(process.cwd(), target.file)}`, async () => {
|
|
3044
|
-
writeInstructionBlock(join5(process.cwd(), target.file), renderProjectAgentInstructions(target.label));
|
|
3045
|
-
}, { optional: true });
|
|
3046
|
-
}
|
|
3047
|
-
console.log(` ${dim("Commit the file to share it. Teammates without a key fall back to the terminal.")}`);
|
|
3048
|
-
};
|
|
3049
|
-
var offerClaudeAlias = async (options) => {
|
|
3050
|
-
if (!process.stdout.isTTY || options.nonInteractive) return;
|
|
3051
|
-
const rc = resolveShellRc();
|
|
3052
|
-
console.log();
|
|
3053
|
-
if (!rc) {
|
|
3054
|
-
console.log(` ${dim("Tip: alias")} ${cyan("claude='pushary claude'")} ${dim("in your shell to make plain")} ${cyan("claude")} ${dim("reachable from your phone.")}`);
|
|
3055
|
-
return;
|
|
3056
|
-
}
|
|
3057
|
-
const wanted = await confirm({
|
|
3058
|
-
message: `Start ${bold("claude")} through Pushary, so your phone can reach idle sessions? This adds an alias to ${basename(rc.path)}.`,
|
|
3059
|
-
default: false
|
|
3060
|
-
});
|
|
3061
|
-
if (!wanted) return;
|
|
3062
|
-
const result = installClaudeAlias();
|
|
3063
|
-
if (result.installed) {
|
|
3064
|
-
console.log(` ${check} Aliased ${cyan("claude")} \u2192 ${cyan("pushary claude")} in ${dim(result.path ?? rc.path)}`);
|
|
3065
|
-
console.log(` ${dim("Open a new terminal (or")} ${cyan(`source ${rc.path}`)}${dim(") to use it. Undo any time with")} ${cyan("pushary clean")}${dim(".")}`);
|
|
3066
|
-
} else if (result.reason === "exists") {
|
|
3067
|
-
console.log(` ${check} ${dim("The")} ${cyan("claude")} ${dim("alias is already set.")}`);
|
|
3068
|
-
}
|
|
3069
|
-
};
|
|
3070
3051
|
var verifyKeyOrExit = async (apiKey, options, precomputed) => {
|
|
3071
3052
|
const live = process.stdout.isTTY === true && !options.json && precomputed === void 0;
|
|
3072
3053
|
if (live) writeHuman(` ${dim("...")} Verifying your key with pushary.com`);
|
|
@@ -3089,7 +3070,8 @@ var verifyKeyOrExit = async (apiKey, options, precomputed) => {
|
|
|
3089
3070
|
process.exit(await abortWith("key-refused", report.exitCode, result.kind));
|
|
3090
3071
|
}
|
|
3091
3072
|
if (result.kind === "ok") {
|
|
3092
|
-
|
|
3073
|
+
const email = someoneIsAtTheTerminal({ stdoutIsTty: process.stdout.isTTY === true, nonInteractive: options.nonInteractive }) ? "show" : "hide";
|
|
3074
|
+
console.log(` ${check} ${describeSignedIn(result.identity, email)}`);
|
|
3093
3075
|
} else {
|
|
3094
3076
|
console.log(` ${yellow("!")} ${report.message}`);
|
|
3095
3077
|
for (const line of report.next) console.log(` ${dim(line)}`);
|
|
@@ -3138,18 +3120,7 @@ var AGENT_NAMES = {
|
|
|
3138
3120
|
...compatibleRecord((profile) => profile.label),
|
|
3139
3121
|
custom: "Other"
|
|
3140
3122
|
};
|
|
3141
|
-
var
|
|
3142
|
-
claude_code: "MCP + hooks + auto-allowed tools",
|
|
3143
|
-
codex: "MCP + native hooks + auto-allowed tools",
|
|
3144
|
-
gemini_cli: "MCP + native hooks + auto-allowed tools",
|
|
3145
|
-
hermes: "native plugin + auto-error notifications",
|
|
3146
|
-
openclaw: "native plugin + exec approval gate",
|
|
3147
|
-
cursor: "plugin + permission gate",
|
|
3148
|
-
vscode: "agent plugin + permission gate",
|
|
3149
|
-
opencode: "generated plugin + permission gate",
|
|
3150
|
-
fx: "MCP through a local bridge + questions via push",
|
|
3151
|
-
cline: "MCP with your key + global rule",
|
|
3152
|
-
...compatibleRecord((profile) => profile.mcp ? "MCP + native hooks" : "native hooks"),
|
|
3123
|
+
var AGENT_PICKER_HINTS = {
|
|
3153
3124
|
custom: "any MCP or HTTP agent (Windsurf, n8n, custom)"
|
|
3154
3125
|
};
|
|
3155
3126
|
var failedAgentNames = (failures) => failures.map((failure) => AGENT_NAMES[failure.agent]);
|
|
@@ -3181,21 +3152,25 @@ var printAgentFailures = (failures) => {
|
|
|
3181
3152
|
}
|
|
3182
3153
|
};
|
|
3183
3154
|
var NAME_COLUMN = Math.max(...Object.values(AGENT_NAMES).map((name) => name.length)) + 2;
|
|
3155
|
+
var pickerLabelOf = (agent) => {
|
|
3156
|
+
const hint = AGENT_PICKER_HINTS[agent];
|
|
3157
|
+
return hint ? `${AGENT_NAMES[agent].padEnd(NAME_COLUMN)}${dim(hint)}` : AGENT_NAMES[agent];
|
|
3158
|
+
};
|
|
3184
3159
|
var AGENT_LABELS = Object.fromEntries(
|
|
3185
|
-
Object.keys(AGENT_NAMES).map((agent) => [
|
|
3186
|
-
agent,
|
|
3187
|
-
`${AGENT_NAMES[agent].padEnd(NAME_COLUMN)}${dim(AGENT_CAPABILITIES[agent])}`
|
|
3188
|
-
])
|
|
3160
|
+
Object.keys(AGENT_NAMES).map((agent) => [agent, pickerLabelOf(agent)])
|
|
3189
3161
|
);
|
|
3190
3162
|
var printSteps = (steps) => {
|
|
3191
3163
|
for (const line of steps) console.log(line);
|
|
3192
3164
|
};
|
|
3193
3165
|
var printAgentLine = (agent, steps) => {
|
|
3194
|
-
console.log(` ${check} ${
|
|
3166
|
+
console.log(` ${check} ${AGENT_NAMES[agent]}`);
|
|
3195
3167
|
printSteps(warningLinesOf(steps));
|
|
3196
3168
|
};
|
|
3197
|
-
var printWhyUnchanged = (steps) => {
|
|
3169
|
+
var printWhyUnchanged = (agent, steps) => {
|
|
3198
3170
|
const warnings = warningLinesOf(steps);
|
|
3171
|
+
if (warnings.length > 0 && !warnings.some((line) => line.includes(AGENT_NAMES[agent]))) {
|
|
3172
|
+
console.log(` ${yellow("!")} ${AGENT_NAMES[agent]} was not set up:`);
|
|
3173
|
+
}
|
|
3199
3174
|
printSteps(warnings.length > 0 ? warnings : steps);
|
|
3200
3175
|
};
|
|
3201
3176
|
var installWithOneLine = async (agent, install) => {
|
|
@@ -3295,7 +3270,7 @@ var resolveAgents = async (options) => {
|
|
|
3295
3270
|
someoneCanAnswer: someoneIsAtTheTerminal({ stdoutIsTty: process.stdout.isTTY === true, nonInteractive: options.nonInteractive })
|
|
3296
3271
|
});
|
|
3297
3272
|
if (selection.kind === "auto") return pickedWithoutAPerson(await selectDetectedAgents(detected), false);
|
|
3298
|
-
const hint = hasDetectedAgents ? "(
|
|
3273
|
+
const hint = hasDetectedAgents ? "(the ones on this computer are ticked)" : "(space = toggle, enter = confirm)";
|
|
3299
3274
|
if (process.stdout.isTTY === true) process.stdout.write(TERMINAL_BELL);
|
|
3300
3275
|
return agentResolutionFromPicker(
|
|
3301
3276
|
await pickAgentsUntilIdle({
|
|
@@ -3521,7 +3496,6 @@ var main = async () => {
|
|
|
3521
3496
|
keyFromPairing = signedIn2.kind === "app";
|
|
3522
3497
|
pairedHandle = signedIn2.kind === "app" && signedIn2.handle ? `@${signedIn2.handle}` : null;
|
|
3523
3498
|
console.log();
|
|
3524
|
-
if (signedIn2.kind === "browser") console.log(` ${check} Signed in${signedIn2.siteSlug ? ` ${dim(`(${signedIn2.siteSlug})`)}` : ""}`);
|
|
3525
3499
|
if (signedIn2.kind === "app") console.log(` ${check} Your phone approved this computer`);
|
|
3526
3500
|
if (pairedHandle) console.log(` ${check} Connected to ${cyan(pairedHandle)}`);
|
|
3527
3501
|
const previousKeyLeftActive = describePreviousKeyLeftActive(previous.key, trimmedKey);
|
|
@@ -3585,8 +3559,6 @@ var main = async () => {
|
|
|
3585
3559
|
phonePass = outcome.phonePass;
|
|
3586
3560
|
keyOrigin = "created_by_this_cli";
|
|
3587
3561
|
console.log();
|
|
3588
|
-
console.log(` ${check} Signed in${outcome.siteSlug ? ` ${dim(`(${outcome.siteSlug})`)}` : ""}`);
|
|
3589
|
-
console.log();
|
|
3590
3562
|
} else if (outcome.kind === "rejected") {
|
|
3591
3563
|
console.log();
|
|
3592
3564
|
console.log(` ${yellow("!")} That request was rejected in the browser. Nothing was written.`);
|
|
@@ -3729,12 +3701,14 @@ var main = async () => {
|
|
|
3729
3701
|
continue;
|
|
3730
3702
|
}
|
|
3731
3703
|
if (ownerBefore === "app") captureTakeoverReceipt(agent);
|
|
3732
|
-
const
|
|
3733
|
-
const
|
|
3704
|
+
const hermesShellGateMayAsk = agent === "hermes" && context.hermesShellGate === "ask" && await withProgressLine(agent, hermesShellGateMayAskNow);
|
|
3705
|
+
const outputMode = agentOutputModeFor({ agent, verbose: options.verbose, hermesShellGate: context.hermesShellGate, hermesShellGateMayAsk });
|
|
3706
|
+
const install = () => AGENT_SETUP[agent](trimmedKey, outputMode === "one-line" ? contextThatNeverAsks(context) : context);
|
|
3707
|
+
const { outcome, steps } = outputMode === "one-line" ? await installWithOneLine(agent, install) : { outcome: await install(), steps: null };
|
|
3734
3708
|
if (outcome === "skipped" || outcome === "unchanged") {
|
|
3735
3709
|
skipped.push(agent);
|
|
3736
3710
|
if (outcome === "unchanged") leftUnchanged.push(agent);
|
|
3737
|
-
if (outcome === "unchanged" && steps) printWhyUnchanged(steps);
|
|
3711
|
+
if (outcome === "unchanged" && steps) printWhyUnchanged(agent, steps);
|
|
3738
3712
|
} else if (outcome === "verified" || await agentIsWired(agent)) {
|
|
3739
3713
|
completed.push(agent);
|
|
3740
3714
|
clearSetupChoiceDecline(agent);
|
|
@@ -3760,10 +3734,6 @@ var main = async () => {
|
|
|
3760
3734
|
console.log();
|
|
3761
3735
|
console.log(` ${yellow("!")} Not configured: ${notInstalled.map((agent) => AGENT_NAMES[agent]).join(", ")} ${dim("(not installed on this machine)")}`);
|
|
3762
3736
|
}
|
|
3763
|
-
if (leftUnchanged.length > 0) {
|
|
3764
|
-
console.log();
|
|
3765
|
-
console.log(` ${yellow("!")} Not configured: ${leftUnchanged.map((agent) => AGENT_NAMES[agent]).join(", ")} ${dim("(the reason is above)")}`);
|
|
3766
|
-
}
|
|
3767
3737
|
if (failures.length > 0) {
|
|
3768
3738
|
console.log();
|
|
3769
3739
|
const configured = failedAgentsContext(completed.map((agent) => AGENT_NAMES[agent]));
|
|
@@ -3771,11 +3741,6 @@ var main = async () => {
|
|
|
3771
3741
|
for (const followUp of agentFailureFollowUps(failures)) console.log(` ${agentFailureFollowUpLine(followUp)}`);
|
|
3772
3742
|
}
|
|
3773
3743
|
showManualStepsSoFar();
|
|
3774
|
-
if (!keyFromPairing && !nobodyAnswered) {
|
|
3775
|
-
markStep("project-instructions");
|
|
3776
|
-
await offerProjectInstructions(agents, options);
|
|
3777
|
-
if (completed.includes("claude_code")) await offerClaudeAlias(options);
|
|
3778
|
-
}
|
|
3779
3744
|
}
|
|
3780
3745
|
if (controlMode === "off") {
|
|
3781
3746
|
markStep("control:disable");
|
|
@@ -3788,8 +3753,10 @@ var main = async () => {
|
|
|
3788
3753
|
}
|
|
3789
3754
|
}
|
|
3790
3755
|
showManualStepsSoFar();
|
|
3756
|
+
const waitWarning = keyCheck.kind === "ok" ? await fetchSetupWaitWarning(trimmedKey) : null;
|
|
3757
|
+
if (waitWarning !== null) console.log(` ${yellow("!")} ${waitWarning}`);
|
|
3758
|
+
const stillToDoEndsTheOutput = manualStepsPrinted > 0 && controlMode !== "off" && waitWarning === null;
|
|
3791
3759
|
markStep(CONNECT_PHONE_STEP);
|
|
3792
|
-
if (keyCheck.kind === "ok") console.log(` ${dim(await fetchSetupWaitGuidance(trimmedKey))}`);
|
|
3793
3760
|
const skipPhone = options.skipPhone;
|
|
3794
3761
|
let phone = null;
|
|
3795
3762
|
const verifyMode = effectiveVerify(options, { paired: keyFromPairing });
|
|
@@ -3834,8 +3801,8 @@ var main = async () => {
|
|
|
3834
3801
|
const keys = keyRouter();
|
|
3835
3802
|
const phoneSignIn = keys !== null && phonePass !== null && connectInstructions.showQr ? await startTerminalPhoneSignIn(phonePass, pairingComputerOf(hostname2(), process.platform, detectedAgentChoices()), reportedInstallSource()) : null;
|
|
3836
3803
|
if (keys === null) phone = await printConnectInstructions(trimmedKey, connectInstructions);
|
|
3837
|
-
else if (phoneSignIn === null) phone = await waitForYourPhone(trimmedKey, { skip: keys.listenerFor(PHONE_WAIT_SKIP_KEY) });
|
|
3838
|
-
else phone = await waitForYourPhoneToSignIn(trimmedKey, phoneSignIn, keys, { say: (line) => console.log(line), bold, dim, cyan, yellow, done: check });
|
|
3804
|
+
else if (phoneSignIn === null) phone = await waitForYourPhone(trimmedKey, { skip: keys.listenerFor(PHONE_WAIT_SKIP_KEY), accountEmail: accountEmailFromCheck(keyCheck), followsABlankLine: stillToDoEndsTheOutput });
|
|
3805
|
+
else phone = await waitForYourPhoneToSignIn(trimmedKey, phoneSignIn, keys, { say: (line) => console.log(line), bold, dim, cyan, yellow, done: check }, { followsABlankLine: stillToDoEndsTheOutput });
|
|
3839
3806
|
keys?.close();
|
|
3840
3807
|
break;
|
|
3841
3808
|
}
|
|
@@ -3860,8 +3827,7 @@ var main = async () => {
|
|
|
3860
3827
|
console.log();
|
|
3861
3828
|
const appPlatforms = phone?.appPlatforms ?? [];
|
|
3862
3829
|
const prompt = describeAnswerTestPrompt(appPlatforms);
|
|
3863
|
-
console.log(` ${dim("Answer the test question on your phone.")}`);
|
|
3864
|
-
if (prompt.step !== null) console.log(` ${dim(prompt.step)}`);
|
|
3830
|
+
console.log(` ${dim(prompt.step === null ? "Answer the test question on your phone." : `Answer the test question on your phone. ${prompt.step}`)}`);
|
|
3865
3831
|
markStep(ANSWER_TEST_STEP);
|
|
3866
3832
|
const answer = verifyRoundTrip(trimmedKey, SETUP_AGENT_NAME, {
|
|
3867
3833
|
interrupted: async (exitCode2) => {
|
|
@@ -3900,7 +3866,7 @@ var main = async () => {
|
|
|
3900
3866
|
reason: keyCheck.kind === "locked" ? "plan_inactive" : "readiness_unverified",
|
|
3901
3867
|
configured: completed,
|
|
3902
3868
|
skipped,
|
|
3903
|
-
manualSteps,
|
|
3869
|
+
manualSteps: [...stepsShownOnTheirRow, ...manualSteps],
|
|
3904
3870
|
failed: failedAgentNames(failures),
|
|
3905
3871
|
agentFailures: failures,
|
|
3906
3872
|
keyCheck: keyCheck.kind,
|
|
@@ -3985,7 +3951,8 @@ var main = async () => {
|
|
|
3985
3951
|
let controlFailureStage = null;
|
|
3986
3952
|
let daemon = null;
|
|
3987
3953
|
if (keyIsTrusted && controlPolicy === "enabled") {
|
|
3988
|
-
|
|
3954
|
+
const serviceNotice = describeServiceInstall(servicePresent);
|
|
3955
|
+
if (serviceNotice !== null) console.log(` ${dim(serviceNotice)}`);
|
|
3989
3956
|
try {
|
|
3990
3957
|
controlFailureStage = "package-install";
|
|
3991
3958
|
await installGlobally2();
|
|
@@ -4095,7 +4062,7 @@ var main = async () => {
|
|
|
4095
4062
|
ok: closing.ok,
|
|
4096
4063
|
configured: completed,
|
|
4097
4064
|
skipped,
|
|
4098
|
-
manualSteps,
|
|
4065
|
+
manualSteps: [...stepsShownOnTheirRow, ...manualSteps],
|
|
4099
4066
|
failed: failedAgentNames(failures),
|
|
4100
4067
|
agentFailures: failures,
|
|
4101
4068
|
hookOwners,
|