@google/gemini-cli 0.65.0-preview.0 → 0.66.0-nightly.20261016.gdebf42324
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/bundle/{chunk-K7AA35SP.js → chunk-3VVLSLUB.js} +365 -230
- package/bundle/{chunk-K7NOVQ6G.js → chunk-4ORY5VV4.js} +376 -231
- package/bundle/{chunk-TP236FKO.js → chunk-4ZQK6FPV.js} +8243 -15166
- package/bundle/{chunk-VF5WQSOE.js → chunk-5U5H7MQT.js} +1 -1
- package/bundle/{chunk-H2CZXS7F.js → chunk-6CPZZAS6.js} +1 -1
- package/bundle/{chunk-2WVLIJA5.js → chunk-6ZNK3R6S.js} +145 -77
- package/bundle/{chunk-NL7ZHGCH.js → chunk-7WET2X2L.js} +1 -1
- package/bundle/{chunk-WTRK3NVX.js → chunk-ARZHETF7.js} +58 -27
- package/bundle/{chunk-HLOOE7YN.js → chunk-C6OZRRSW.js} +9 -8
- package/bundle/{chunk-LLE5Z636.js → chunk-CAK3GIEX.js} +58 -27
- package/bundle/{chunk-F6AJM4WN.js → chunk-DZK3RTN5.js} +3 -3
- package/bundle/{chunk-BFIV7GTA.js → chunk-EAJQUKYV.js} +2 -2
- package/bundle/{chunk-SN7QZKXC.js → chunk-EDXPBFMP.js} +122 -78
- package/bundle/{chunk-43EXRO7A.js → chunk-FMKAMURR.js} +145 -77
- package/bundle/{chunk-RPHDSDL6.js → chunk-GYABHSAN.js} +1 -1
- package/bundle/chunk-HZ3ULZA5.js +512 -0
- package/bundle/{chunk-V72FRESD.js → chunk-IPP4LAIJ.js} +2 -2
- package/bundle/{chunk-S7BCRBI4.js → chunk-L2JWNZ5I.js} +1 -1
- package/bundle/{chunk-4DCA4L53.js → chunk-LE7CRIQW.js} +2 -2
- package/bundle/{chunk-K4G5D5ZZ.js → chunk-NTMOGT2U.js} +1 -1
- package/bundle/{chunk-QJK54DSE.js → chunk-O7DL5A6M.js} +1 -1
- package/bundle/chunk-OUQNYX72.js +425 -0
- package/bundle/{chunk-GSQEBEGC.js → chunk-OWNTY4ZJ.js} +3 -3
- package/bundle/chunk-RATJW3IC.js +103284 -0
- package/bundle/{chunk-WGL5FJOS.js → chunk-RHS7LQYQ.js} +3 -3
- package/bundle/{chunk-V2R74WAG.js → chunk-T526OHX2.js} +151 -81
- package/bundle/chunk-TM5LN2M4.js +118 -0
- package/bundle/{chunk-4JGVVJGK.js → chunk-W4TOIVW2.js} +1 -1
- package/bundle/chunk-WWLKAUPJ.js +1571 -0
- package/bundle/chunk-XMMD2D57.js +154 -0
- package/bundle/chunk-XTRL4LHU.js +402181 -0
- package/bundle/chunk-YDKHD3KR.js +17603 -0
- package/bundle/{cleanup-HPADDONA.js → cleanup-D64VZM4F.js} +2 -2
- package/bundle/{cleanup-JOMSXKMP.js → cleanup-KQSUSZVK.js} +2 -2
- package/bundle/{cleanup-LYRJHMMO.js → cleanup-NFDCMZNM.js} +2 -2
- package/bundle/cleanup-PMQAGUR6.js +32 -0
- package/bundle/{core-NCJTYARO.js → core-AQSWLJFK.js} +13 -1
- package/bundle/{devtoolsService-HIZA3JGR.js → devtoolsService-4FKRWPRR.js} +2 -2
- package/bundle/{devtoolsService-WP2OPVPB.js → devtoolsService-HIMQQKQU.js} +2 -2
- package/bundle/{devtoolsService-JFJBTZ4B.js → devtoolsService-HNNM7RMB.js} +4 -3
- package/bundle/devtoolsService-ZFRR4BWT.js +4359 -0
- package/bundle/{dist-GQKLLBDW.js → dist-5ASSTNQ6.js} +13 -1
- package/bundle/{core-IVQAI4S6.js → dist-BLHNJM7E.js} +13 -1
- package/bundle/dist-KGTOLDFD.js +2280 -0
- package/bundle/docs/changelogs/index.md +22 -0
- package/bundle/docs/changelogs/latest.md +64 -54
- package/bundle/docs/changelogs/preview.md +91 -55
- package/bundle/docs/reference/configuration.md +8 -3
- package/bundle/{gemini-7CHJYSHM.js → gemini-5A6XE5MS.js} +14 -14
- package/bundle/{gemini-5TUKZVGS.js → gemini-6AUGEYTK.js} +14 -14
- package/bundle/{gemini-546WMAHG.js → gemini-CONRUIWA.js} +214 -198
- package/bundle/gemini-NNDIP5FI.js +17951 -0
- package/bundle/gemini.js +7 -7
- package/bundle/{interactiveCli-5XIAIY74.js → interactiveCli-4ASTHC7A.js} +1370 -1279
- package/bundle/{interactiveCli-L4PK7YY3.js → interactiveCli-A4AHHCYK.js} +1060 -988
- package/bundle/interactiveCli-BYRGNC52.js +35601 -0
- package/bundle/{interactiveCli-E3PUPYMZ.js → interactiveCli-DVYUBC7X.js} +1060 -988
- package/bundle/{liteRtServerManager-JCTYJBV5.js → liteRtServerManager-4YCGFHXM.js} +4 -4
- package/bundle/{liteRtServerManager-JERG6KYC.js → liteRtServerManager-B5VXJYB6.js} +4 -4
- package/bundle/{liteRtServerManager-22ISMNN2.js → liteRtServerManager-O5MQ7YAM.js} +4 -4
- package/bundle/liteRtServerManager-XTK5NKOU.js +65 -0
- package/bundle/{oauth2-provider-MKWWBW4K.js → oauth2-provider-DGDIJBPB.js} +1 -1
- package/bundle/{oauth2-provider-XRUER2XR.js → oauth2-provider-FL4LAMOD.js} +1 -1
- package/bundle/{oauth2-provider-477UJQX6.js → oauth2-provider-LJCH3JL4.js} +41 -79
- package/bundle/oauth2-provider-XMOANRFY.js +273 -0
- package/bundle/{start-MVIPJNQ5.js → start-EK5VVD43.js} +6 -6
- package/bundle/{start-RZWSVT55.js → start-EZBPBQGC.js} +6 -6
- package/bundle/{start-AGMBPY3O.js → start-TTVQ72ZW.js} +6 -6
- package/bundle/start-ZK46NOA3.js +18 -0
- package/package.json +1 -1
|
@@ -2,7 +2,7 @@ const require = (await import('node:module')).createRequire(import.meta.url); co
|
|
|
2
2
|
import {
|
|
3
3
|
exitCli,
|
|
4
4
|
require_source
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-W4TOIVW2.js";
|
|
6
6
|
import {
|
|
7
7
|
AppEvent,
|
|
8
8
|
appEvents
|
|
@@ -63,21 +63,23 @@ import {
|
|
|
63
63
|
stripUnsafeCharacters,
|
|
64
64
|
toCodePoints,
|
|
65
65
|
validateCustomTheme
|
|
66
|
-
} from "./chunk-
|
|
66
|
+
} from "./chunk-T526OHX2.js";
|
|
67
67
|
import {
|
|
68
68
|
isDevelopment
|
|
69
|
-
} from "./chunk-
|
|
69
|
+
} from "./chunk-LE7CRIQW.js";
|
|
70
70
|
import {
|
|
71
71
|
emptyIcon,
|
|
72
72
|
mapCoreStatusToDisplayStatus,
|
|
73
73
|
require_react
|
|
74
|
-
} from "./chunk-
|
|
74
|
+
} from "./chunk-7WET2X2L.js";
|
|
75
75
|
import {
|
|
76
76
|
ALL_EDITORS,
|
|
77
77
|
ApprovalMode,
|
|
78
78
|
AsyncFzf,
|
|
79
|
+
AuthType,
|
|
79
80
|
Config,
|
|
80
81
|
CoreEvent,
|
|
82
|
+
CoreToolCallStatus,
|
|
81
83
|
DiscoveredMCPTool,
|
|
82
84
|
ExtensionDisableEvent,
|
|
83
85
|
ExtensionEnableEvent,
|
|
@@ -88,21 +90,32 @@ import {
|
|
|
88
90
|
ExtensionUpdateEvent,
|
|
89
91
|
GEMINI_CLI_COMPANION_EXTENSION_NAME,
|
|
90
92
|
GEMINI_DIR,
|
|
93
|
+
HookType,
|
|
94
|
+
IDEConnectionStatus,
|
|
91
95
|
INITIAL_HISTORY_LENGTH,
|
|
92
96
|
IdeClient,
|
|
93
97
|
IdeConnectionEvent,
|
|
98
|
+
IdeConnectionType,
|
|
99
|
+
IntegrityDataStatus,
|
|
94
100
|
KeychainTokenStorage,
|
|
101
|
+
LlmRole,
|
|
102
|
+
MCPDiscoveryState,
|
|
95
103
|
MCPOAuthTokenStorage,
|
|
104
|
+
MCPServerStatus,
|
|
96
105
|
ModelSlashCommandEvent,
|
|
106
|
+
PolicyDecision,
|
|
97
107
|
ProjectIdRequiredError,
|
|
98
108
|
REFERENCE_CONTENT_END,
|
|
99
109
|
REFERENCE_CONTENT_START,
|
|
100
110
|
ReadManyFilesTool,
|
|
101
111
|
RewindEvent,
|
|
102
112
|
SHELL_TOOL_NAME,
|
|
113
|
+
SessionEndReason,
|
|
114
|
+
SessionStartSource,
|
|
103
115
|
ShellExecutionService,
|
|
104
116
|
StartSessionEvent,
|
|
105
117
|
Storage,
|
|
118
|
+
TrustLevel,
|
|
106
119
|
UPGRADE_URL_PAGE,
|
|
107
120
|
UserAccountManager,
|
|
108
121
|
ValidationRequiredError,
|
|
@@ -177,6 +190,7 @@ import {
|
|
|
177
190
|
isProjectSkillPatchTarget,
|
|
178
191
|
isSubpath,
|
|
179
192
|
isTerminalEditor,
|
|
193
|
+
isTmux,
|
|
180
194
|
isValidEditorType,
|
|
181
195
|
is_wsl_default,
|
|
182
196
|
listExtensions,
|
|
@@ -241,7 +255,7 @@ import {
|
|
|
241
255
|
uiTelemetryService,
|
|
242
256
|
unescapePath,
|
|
243
257
|
validateUrlDestination
|
|
244
|
-
} from "./chunk-
|
|
258
|
+
} from "./chunk-3VVLSLUB.js";
|
|
245
259
|
import {
|
|
246
260
|
require_src
|
|
247
261
|
} from "./chunk-L6PII3GR.js";
|
|
@@ -7841,14 +7855,14 @@ var require_react_reconciler_production = __commonJS({
|
|
|
7841
7855
|
}
|
|
7842
7856
|
var exports2 = {};
|
|
7843
7857
|
"use strict";
|
|
7844
|
-
var
|
|
7858
|
+
var React23 = require_react(), Scheduler = require_scheduler(), assign = Object.assign, REACT_LEGACY_ELEMENT_TYPE = Symbol.for("react.element"), REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"), REACT_PROFILER_TYPE = Symbol.for("react.profiler"), REACT_PROVIDER_TYPE = Symbol.for("react.provider"), REACT_CONSUMER_TYPE = Symbol.for("react.consumer"), REACT_CONTEXT_TYPE = Symbol.for("react.context"), REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"), REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"), REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"), REACT_MEMO_TYPE = Symbol.for("react.memo"), REACT_LAZY_TYPE = Symbol.for("react.lazy");
|
|
7845
7859
|
Symbol.for("react.scope");
|
|
7846
7860
|
var REACT_ACTIVITY_TYPE = Symbol.for("react.activity");
|
|
7847
7861
|
Symbol.for("react.legacy_hidden");
|
|
7848
7862
|
Symbol.for("react.tracing_marker");
|
|
7849
7863
|
var REACT_MEMO_CACHE_SENTINEL = Symbol.for("react.memo_cache_sentinel");
|
|
7850
7864
|
Symbol.for("react.view_transition");
|
|
7851
|
-
var MAYBE_ITERATOR_SYMBOL = Symbol.iterator, REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"), isArrayImpl = Array.isArray, ReactSharedInternals =
|
|
7865
|
+
var MAYBE_ITERATOR_SYMBOL = Symbol.iterator, REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"), isArrayImpl = Array.isArray, ReactSharedInternals = React23.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, rendererVersion = $$$config.rendererVersion, rendererPackageName = $$$config.rendererPackageName, extraDevToolsConfig = $$$config.extraDevToolsConfig, getPublicInstance = $$$config.getPublicInstance, getRootHostContext = $$$config.getRootHostContext, getChildHostContext = $$$config.getChildHostContext, prepareForCommit = $$$config.prepareForCommit, resetAfterCommit = $$$config.resetAfterCommit, createInstance = $$$config.createInstance;
|
|
7852
7866
|
$$$config.cloneMutableInstance;
|
|
7853
7867
|
var appendInitialChild = $$$config.appendInitialChild, finalizeInitialChildren = $$$config.finalizeInitialChildren, shouldSetTextContent = $$$config.shouldSetTextContent, createTextInstance = $$$config.createTextInstance;
|
|
7854
7868
|
$$$config.cloneMutableTextInstance;
|
|
@@ -60109,7 +60123,7 @@ var import_react34 = __toESM(require_react(), 1);
|
|
|
60109
60123
|
function useIdeTrustListener() {
|
|
60110
60124
|
const settings = useSettings();
|
|
60111
60125
|
const [connectionStatus, setConnectionStatus] = (0, import_react34.useState)(
|
|
60112
|
-
|
|
60126
|
+
IDEConnectionStatus.Disconnected
|
|
60113
60127
|
);
|
|
60114
60128
|
const previousTrust = (0, import_react34.useRef)(void 0);
|
|
60115
60129
|
const [restartReason, setRestartReason] = (0, import_react34.useState)("NONE");
|
|
@@ -60139,7 +60153,7 @@ function useIdeTrustListener() {
|
|
|
60139
60153
|
};
|
|
60140
60154
|
}, []);
|
|
60141
60155
|
const getSnapshot = () => {
|
|
60142
|
-
if (connectionStatus !==
|
|
60156
|
+
if (connectionStatus !== IDEConnectionStatus.Connected) {
|
|
60143
60157
|
return void 0;
|
|
60144
60158
|
}
|
|
60145
60159
|
return ideContextStore.get()?.workspaceState?.isTrusted;
|
|
@@ -60844,7 +60858,7 @@ async function initializeApp(config, settings) {
|
|
|
60844
60858
|
await ideClient.connect();
|
|
60845
60859
|
logIdeConnection(
|
|
60846
60860
|
config,
|
|
60847
|
-
new IdeConnectionEvent(
|
|
60861
|
+
new IdeConnectionEvent(IdeConnectionType.START)
|
|
60848
60862
|
);
|
|
60849
60863
|
}).catch((e) => {
|
|
60850
60864
|
debugLogger.error("Failed to initialize IDE client:", e);
|
|
@@ -60862,17 +60876,17 @@ async function initializeApp(config, settings) {
|
|
|
60862
60876
|
// packages/cli/src/config/auth.ts
|
|
60863
60877
|
async function validateAuthMethod(authMethod) {
|
|
60864
60878
|
loadEnvironment(loadSettings().merged, process.cwd());
|
|
60865
|
-
if (authMethod ===
|
|
60879
|
+
if (authMethod === AuthType.LOGIN_WITH_GOOGLE || authMethod === AuthType.COMPUTE_ADC) {
|
|
60866
60880
|
return null;
|
|
60867
60881
|
}
|
|
60868
|
-
if (authMethod ===
|
|
60882
|
+
if (authMethod === AuthType.USE_GEMINI) {
|
|
60869
60883
|
const key = process.env["GEMINI_API_KEY"] || await loadApiKey();
|
|
60870
60884
|
if (!key) {
|
|
60871
60885
|
return "When using Gemini API, you must specify the GEMINI_API_KEY environment variable.\nUpdate your environment and try again (no reload needed if using .env)!";
|
|
60872
60886
|
}
|
|
60873
60887
|
return null;
|
|
60874
60888
|
}
|
|
60875
|
-
if (authMethod ===
|
|
60889
|
+
if (authMethod === AuthType.USE_VERTEX_AI) {
|
|
60876
60890
|
const hasVertexProjectLocationConfig = !!process.env["GOOGLE_CLOUD_PROJECT"] && !!process.env["GOOGLE_CLOUD_LOCATION"];
|
|
60877
60891
|
const hasGoogleApiKey = !!process.env["GOOGLE_API_KEY"];
|
|
60878
60892
|
if (!hasVertexProjectLocationConfig && !hasGoogleApiKey) {
|
|
@@ -65553,7 +65567,7 @@ var ExtensionManager = class extends ExtensionLoader {
|
|
|
65553
65567
|
const trustedFolders = loadTrustedFolders();
|
|
65554
65568
|
await trustedFolders.setValue(
|
|
65555
65569
|
this.workspaceDir,
|
|
65556
|
-
|
|
65570
|
+
TrustLevel.TRUST_FOLDER
|
|
65557
65571
|
);
|
|
65558
65572
|
} else {
|
|
65559
65573
|
throw new Error(
|
|
@@ -65739,7 +65753,7 @@ Would you like to attempt to install via "git clone" instead?`
|
|
|
65739
65753
|
newExtensionConfig.version,
|
|
65740
65754
|
previousExtensionConfig.version,
|
|
65741
65755
|
installMetadata.type,
|
|
65742
|
-
|
|
65756
|
+
CoreToolCallStatus.Success
|
|
65743
65757
|
)
|
|
65744
65758
|
);
|
|
65745
65759
|
if (newExtensionName !== previousName) {
|
|
@@ -65762,7 +65776,7 @@ Would you like to attempt to install via "git clone" instead?`
|
|
|
65762
65776
|
getExtensionId(newExtensionConfig, installMetadata),
|
|
65763
65777
|
newExtensionConfig.version,
|
|
65764
65778
|
installMetadata.type,
|
|
65765
|
-
|
|
65779
|
+
CoreToolCallStatus.Success
|
|
65766
65780
|
)
|
|
65767
65781
|
);
|
|
65768
65782
|
await this.enableExtension(
|
|
@@ -65801,7 +65815,7 @@ Would you like to attempt to install via "git clone" instead?`
|
|
|
65801
65815
|
newExtensionConfig?.version ?? "",
|
|
65802
65816
|
previousExtensionConfig.version,
|
|
65803
65817
|
installMetadata.type,
|
|
65804
|
-
|
|
65818
|
+
CoreToolCallStatus.Error
|
|
65805
65819
|
)
|
|
65806
65820
|
);
|
|
65807
65821
|
} else {
|
|
@@ -65813,7 +65827,7 @@ Would you like to attempt to install via "git clone" instead?`
|
|
|
65813
65827
|
extensionId ?? "",
|
|
65814
65828
|
newExtensionConfig?.version ?? "",
|
|
65815
65829
|
installMetadata.type,
|
|
65816
|
-
|
|
65830
|
+
CoreToolCallStatus.Error
|
|
65817
65831
|
)
|
|
65818
65832
|
);
|
|
65819
65833
|
}
|
|
@@ -65841,7 +65855,7 @@ Would you like to attempt to install via "git clone" instead?`
|
|
|
65841
65855
|
extension.name,
|
|
65842
65856
|
hashValue(extension.name),
|
|
65843
65857
|
extension.id,
|
|
65844
|
-
|
|
65858
|
+
CoreToolCallStatus.Success
|
|
65845
65859
|
)
|
|
65846
65860
|
);
|
|
65847
65861
|
}
|
|
@@ -66104,7 +66118,7 @@ Would you like to attempt to install via "git clone" instead?`
|
|
|
66104
66118
|
if (eventHooks) {
|
|
66105
66119
|
for (const definition of eventHooks) {
|
|
66106
66120
|
for (const hook of definition.hooks) {
|
|
66107
|
-
if (hook.type ===
|
|
66121
|
+
if (hook.type === HookType.Command) {
|
|
66108
66122
|
hook.env = { ...hook.env, ...hookEnv };
|
|
66109
66123
|
}
|
|
66110
66124
|
}
|
|
@@ -67241,7 +67255,7 @@ async function readMcpResources(resourceParts, config, signal) {
|
|
|
67241
67255
|
callId: `mcp-resource-${resource.serverName}-${resource.uri}`,
|
|
67242
67256
|
name: `resources/read (${resource.serverName})`,
|
|
67243
67257
|
description: resource.uri,
|
|
67244
|
-
status:
|
|
67258
|
+
status: CoreToolCallStatus.Success,
|
|
67245
67259
|
isClientInitiated: true,
|
|
67246
67260
|
resultDisplay: `Successfully read resource ${resource.uri}`,
|
|
67247
67261
|
confirmationDetails: void 0
|
|
@@ -67256,7 +67270,7 @@ async function readMcpResources(resourceParts, config, signal) {
|
|
|
67256
67270
|
callId: `mcp-resource-${resource.serverName}-${resource.uri}`,
|
|
67257
67271
|
name: `resources/read (${resource.serverName})`,
|
|
67258
67272
|
description: resource.uri,
|
|
67259
|
-
status:
|
|
67273
|
+
status: CoreToolCallStatus.Error,
|
|
67260
67274
|
isClientInitiated: true,
|
|
67261
67275
|
resultDisplay: `Error reading resource ${resource.uri}: ${getErrorMessage(error)}`,
|
|
67262
67276
|
confirmationDetails: void 0
|
|
@@ -67281,7 +67295,7 @@ Content from @${result.uri}:
|
|
|
67281
67295
|
}
|
|
67282
67296
|
if (hasError) {
|
|
67283
67297
|
const firstError = displays.find(
|
|
67284
|
-
(d) => d.status ===
|
|
67298
|
+
(d) => d.status === CoreToolCallStatus.Error
|
|
67285
67299
|
);
|
|
67286
67300
|
return {
|
|
67287
67301
|
parts: [],
|
|
@@ -67320,7 +67334,7 @@ async function readLocalFiles(resolvedFiles, config, signal, userMessageTimestam
|
|
|
67320
67334
|
callId: `client-read-${userMessageTimestamp}`,
|
|
67321
67335
|
name: readManyFilesTool.displayName,
|
|
67322
67336
|
description: invocation.getDescription(),
|
|
67323
|
-
status:
|
|
67337
|
+
status: CoreToolCallStatus.Success,
|
|
67324
67338
|
isClientInitiated: true,
|
|
67325
67339
|
resultDisplay: result.returnDisplay || `Successfully read: ${fileLabelsForDisplay.join(", ")}`,
|
|
67326
67340
|
confirmationDetails: void 0
|
|
@@ -67367,7 +67381,7 @@ Content from @${displayPath}:
|
|
|
67367
67381
|
callId: `client-read-${userMessageTimestamp}`,
|
|
67368
67382
|
name: readManyFilesTool.displayName,
|
|
67369
67383
|
description: invocation?.getDescription() ?? "Error attempting to execute tool to read files",
|
|
67370
|
-
status:
|
|
67384
|
+
status: CoreToolCallStatus.Error,
|
|
67371
67385
|
isClientInitiated: true,
|
|
67372
67386
|
resultDisplay: `Error reading files (${fileLabelsForDisplay.join(", ")}): ${getErrorMessage(error)}`,
|
|
67373
67387
|
confirmationDetails: void 0
|
|
@@ -70634,7 +70648,7 @@ async function openFileInEditor(filePath, stdin, setRawMode, preferredEditorType
|
|
|
70634
70648
|
if (wasRaw) {
|
|
70635
70649
|
setRawMode?.(true);
|
|
70636
70650
|
}
|
|
70637
|
-
coreEvents.emit(
|
|
70651
|
+
coreEvents.emit(CoreEvent.ExternalEditorClosed);
|
|
70638
70652
|
}
|
|
70639
70653
|
}
|
|
70640
70654
|
|
|
@@ -73328,7 +73342,7 @@ async function updateExtension(extension, extensionManager, currentState, dispat
|
|
|
73328
73342
|
extension.name,
|
|
73329
73343
|
installMetadata
|
|
73330
73344
|
);
|
|
73331
|
-
if (status ===
|
|
73345
|
+
if (status === IntegrityDataStatus.INVALID) {
|
|
73332
73346
|
throw new Error("Extension integrity cannot be verified");
|
|
73333
73347
|
}
|
|
73334
73348
|
} catch (e) {
|
|
@@ -74600,13 +74614,14 @@ var formatDuration = (milliseconds) => {
|
|
|
74600
74614
|
if (milliseconds <= 0) {
|
|
74601
74615
|
return "0s";
|
|
74602
74616
|
}
|
|
74603
|
-
|
|
74604
|
-
|
|
74617
|
+
const roundedMs = Math.round(milliseconds);
|
|
74618
|
+
if (roundedMs < 1e3) {
|
|
74619
|
+
return `${roundedMs}ms`;
|
|
74605
74620
|
}
|
|
74606
|
-
|
|
74607
|
-
|
|
74608
|
-
return `${totalSeconds.toFixed(1)}s`;
|
|
74621
|
+
if (milliseconds < 59950) {
|
|
74622
|
+
return `${(milliseconds / 1e3).toFixed(1)}s`;
|
|
74609
74623
|
}
|
|
74624
|
+
const totalSeconds = Math.round(milliseconds / 1e3);
|
|
74610
74625
|
const hours = Math.floor(totalSeconds / 3600);
|
|
74611
74626
|
const minutes = Math.floor(totalSeconds % 3600 / 60);
|
|
74612
74627
|
const seconds = Math.floor(totalSeconds % 60);
|
|
@@ -74823,11 +74838,11 @@ var ShellProcessor = class {
|
|
|
74823
74838
|
},
|
|
74824
74839
|
void 0
|
|
74825
74840
|
);
|
|
74826
|
-
if (decision ===
|
|
74841
|
+
if (decision === PolicyDecision.DENY) {
|
|
74827
74842
|
throw new Error(
|
|
74828
74843
|
`${this.commandName} cannot be run. Blocked command: "${command}". Reason: Blocked by policy.`
|
|
74829
74844
|
);
|
|
74830
|
-
} else if (decision ===
|
|
74845
|
+
} else if (decision === PolicyDecision.ASK_USER) {
|
|
74831
74846
|
commandsToConfirm.add(command);
|
|
74832
74847
|
}
|
|
74833
74848
|
}
|
|
@@ -75957,7 +75972,7 @@ var MultiFolderTrustDialog = ({
|
|
|
75957
75972
|
if (choice === 1 /* YES_AND_REMEMBER */) {
|
|
75958
75973
|
await trustedFolders.setValue(
|
|
75959
75974
|
expandedPath,
|
|
75960
|
-
|
|
75975
|
+
TrustLevel.TRUST_FOLDER
|
|
75961
75976
|
);
|
|
75962
75977
|
}
|
|
75963
75978
|
workspaceContext.addDirectory(expandedPath);
|
|
@@ -76054,25 +76069,53 @@ function Spinner({ type = "dots" }) {
|
|
|
76054
76069
|
var build_default = Spinner;
|
|
76055
76070
|
|
|
76056
76071
|
// packages/cli/src/ui/components/CliSpinner.tsx
|
|
76072
|
+
var import_cli_spinners2 = __toESM(require_cli_spinners(), 1);
|
|
76057
76073
|
var import_react53 = __toESM(require_react(), 1);
|
|
76058
76074
|
var import_jsx_runtime11 = __toESM(require_jsx_runtime(), 1);
|
|
76059
|
-
var
|
|
76060
|
-
|
|
76061
|
-
|
|
76062
|
-
|
|
76063
|
-
|
|
76064
|
-
|
|
76075
|
+
var TMUX_SPINNER_INTERVAL_MS = 120;
|
|
76076
|
+
var TmuxSpinner = import_react53.default.memo(
|
|
76077
|
+
({ type = "dots" }) => {
|
|
76078
|
+
const [frame, setFrame] = (0, import_react53.useState)(0);
|
|
76079
|
+
const spinner = import_cli_spinners2.default[type] ?? import_cli_spinners2.default.dots;
|
|
76080
|
+
const intervalMs = Math.max(spinner.interval, TMUX_SPINNER_INTERVAL_MS);
|
|
76081
|
+
(0, import_react53.useEffect)(() => {
|
|
76082
|
+
const timer = setInterval(() => {
|
|
76083
|
+
setFrame(
|
|
76084
|
+
(previousFrame) => previousFrame >= spinner.frames.length - 1 ? 0 : previousFrame + 1
|
|
76085
|
+
);
|
|
76086
|
+
}, intervalMs);
|
|
76065
76087
|
return () => {
|
|
76066
|
-
|
|
76088
|
+
clearInterval(timer);
|
|
76067
76089
|
};
|
|
76090
|
+
}, [spinner, intervalMs]);
|
|
76091
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(Text, { children: spinner.frames[frame % spinner.frames.length] });
|
|
76092
|
+
}
|
|
76093
|
+
);
|
|
76094
|
+
TmuxSpinner.displayName = "TmuxSpinner";
|
|
76095
|
+
var CliSpinner = import_react53.default.memo(
|
|
76096
|
+
(props) => {
|
|
76097
|
+
const settings = useSettings();
|
|
76098
|
+
const shouldShow = settings.merged.ui?.showSpinner !== false;
|
|
76099
|
+
const inTmux2 = isTmux();
|
|
76100
|
+
(0, import_react53.useEffect)(() => {
|
|
76101
|
+
if (shouldShow) {
|
|
76102
|
+
debugState.debugNumAnimatedComponents++;
|
|
76103
|
+
return () => {
|
|
76104
|
+
debugState.debugNumAnimatedComponents--;
|
|
76105
|
+
};
|
|
76106
|
+
}
|
|
76107
|
+
return void 0;
|
|
76108
|
+
}, [shouldShow]);
|
|
76109
|
+
if (!shouldShow) {
|
|
76110
|
+
return null;
|
|
76068
76111
|
}
|
|
76069
|
-
|
|
76070
|
-
|
|
76071
|
-
|
|
76072
|
-
return
|
|
76112
|
+
if (inTmux2) {
|
|
76113
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(TmuxSpinner, { type: props.type });
|
|
76114
|
+
}
|
|
76115
|
+
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(build_default, { ...props });
|
|
76073
76116
|
}
|
|
76074
|
-
|
|
76075
|
-
|
|
76117
|
+
);
|
|
76118
|
+
CliSpinner.displayName = "CliSpinner";
|
|
76076
76119
|
|
|
76077
76120
|
// packages/cli/src/ui/components/shared/ExpandableText.tsx
|
|
76078
76121
|
var import_react54 = __toESM(require_react(), 1);
|
|
@@ -76243,10 +76286,10 @@ function isShellTool(name) {
|
|
|
76243
76286
|
return name === SHELL_COMMAND_NAME || name === SHELL_NAME || name === SHELL_TOOL_NAME || normalized === "shell";
|
|
76244
76287
|
}
|
|
76245
76288
|
function isThisShellFocusable(name, status, config) {
|
|
76246
|
-
return !!(isShellTool(name) && status ===
|
|
76289
|
+
return !!(isShellTool(name) && status === CoreToolCallStatus.Executing && config?.getEnableInteractiveShell());
|
|
76247
76290
|
}
|
|
76248
76291
|
function isThisShellFocused(name, status, ptyId, activeShellPtyId, embeddedShellFocused) {
|
|
76249
|
-
return !!(isShellTool(name) && status ===
|
|
76292
|
+
return !!(isShellTool(name) && status === CoreToolCallStatus.Executing && ptyId === activeShellPtyId && embeddedShellFocused);
|
|
76250
76293
|
}
|
|
76251
76294
|
function useFocusHint(isThisShellFocusable2, isThisShellFocused2, resultDisplay) {
|
|
76252
76295
|
const [userHasFocused, setUserHasFocused] = (0, import_react56.useState)(false);
|
|
@@ -76406,14 +76449,14 @@ function getToolGroupBorderAppearance(item, activeShellPtyId, embeddedShellFocus
|
|
|
76406
76449
|
if (isTrackedToolCall(t)) {
|
|
76407
76450
|
return t.status !== "success" && t.status !== "error" && t.status !== "cancelled";
|
|
76408
76451
|
} else {
|
|
76409
|
-
return t.status !==
|
|
76452
|
+
return t.status !== CoreToolCallStatus.Success && t.status !== CoreToolCallStatus.Error && t.status !== CoreToolCallStatus.Cancelled;
|
|
76410
76453
|
}
|
|
76411
76454
|
});
|
|
76412
76455
|
const isEmbeddedShellFocused = toolsToInspect.some((t) => {
|
|
76413
76456
|
if (isTrackedToolCall(t)) {
|
|
76414
76457
|
return isShellTool(t.request.name) && t.status === "executing" && t.pid === activeShellPtyId && !!embeddedShellFocused;
|
|
76415
76458
|
} else {
|
|
76416
|
-
return isShellTool(t.name) && t.status ===
|
|
76459
|
+
return isShellTool(t.name) && t.status === CoreToolCallStatus.Executing && t.ptyId === activeShellPtyId && !!embeddedShellFocused;
|
|
76417
76460
|
}
|
|
76418
76461
|
});
|
|
76419
76462
|
const isShellCommand = toolsToInspect.some((t) => {
|
|
@@ -77851,7 +77894,7 @@ var authCommand = {
|
|
|
77851
77894
|
import process29 from "node:process";
|
|
77852
77895
|
|
|
77853
77896
|
// packages/cli/src/generated/git-commit.ts
|
|
77854
|
-
var GIT_COMMIT_INFO = "
|
|
77897
|
+
var GIT_COMMIT_INFO = "debf42324";
|
|
77855
77898
|
|
|
77856
77899
|
// packages/cli/src/ui/utils/historyExportUtils.ts
|
|
77857
77900
|
import * as fsPromises from "node:fs/promises";
|
|
@@ -78497,7 +78540,7 @@ var clearCommand = {
|
|
|
78497
78540
|
const config = context.services.agentContext?.config;
|
|
78498
78541
|
const hookSystem = config?.getHookSystem();
|
|
78499
78542
|
if (hookSystem) {
|
|
78500
|
-
await hookSystem.fireSessionEndEvent(
|
|
78543
|
+
await hookSystem.fireSessionEndEvent(SessionEndReason.Clear);
|
|
78501
78544
|
}
|
|
78502
78545
|
config?.injectionService.clear();
|
|
78503
78546
|
let newSessionId;
|
|
@@ -78514,7 +78557,7 @@ var clearCommand = {
|
|
|
78514
78557
|
}
|
|
78515
78558
|
let result;
|
|
78516
78559
|
if (hookSystem) {
|
|
78517
|
-
result = await hookSystem.fireSessionStartEvent(
|
|
78560
|
+
result = await hookSystem.fireSessionStartEvent(SessionStartSource.Clear);
|
|
78518
78561
|
}
|
|
78519
78562
|
await new Promise((resolve9) => setImmediate(resolve9));
|
|
78520
78563
|
if (config) {
|
|
@@ -81523,7 +81566,7 @@ var Footer = () => {
|
|
|
81523
81566
|
case "auth": {
|
|
81524
81567
|
if (!settings.merged.ui.showUserIdentity) break;
|
|
81525
81568
|
if (!authType) break;
|
|
81526
|
-
const displayStr = authType ===
|
|
81569
|
+
const displayStr = authType === AuthType.LOGIN_WITH_GOOGLE ? email ?? "google" : authType;
|
|
81527
81570
|
addCol(
|
|
81528
81571
|
id,
|
|
81529
81572
|
header,
|
|
@@ -83307,12 +83350,12 @@ import path29 from "node:path";
|
|
|
83307
83350
|
function getIdeStatusMessage(ideClient) {
|
|
83308
83351
|
const connection = ideClient.getConnectionStatus();
|
|
83309
83352
|
switch (connection.status) {
|
|
83310
|
-
case
|
|
83353
|
+
case IDEConnectionStatus.Connected:
|
|
83311
83354
|
return {
|
|
83312
83355
|
messageType: "info",
|
|
83313
83356
|
content: `\u{1F7E2} Connected to ${ideClient.getDetectedIdeDisplayName()}`
|
|
83314
83357
|
};
|
|
83315
|
-
case
|
|
83358
|
+
case IDEConnectionStatus.Connecting:
|
|
83316
83359
|
return {
|
|
83317
83360
|
messageType: "info",
|
|
83318
83361
|
content: `\u{1F7E1} Connecting...`
|
|
@@ -83353,7 +83396,7 @@ ${infoMessage}`;
|
|
|
83353
83396
|
async function getIdeStatusMessageWithFiles(ideClient) {
|
|
83354
83397
|
const connection = ideClient.getConnectionStatus();
|
|
83355
83398
|
switch (connection.status) {
|
|
83356
|
-
case
|
|
83399
|
+
case IDEConnectionStatus.Connected: {
|
|
83357
83400
|
let content = `\u{1F7E2} Connected to ${ideClient.getDetectedIdeDisplayName()}`;
|
|
83358
83401
|
const context = ideContextStore.get();
|
|
83359
83402
|
const openFiles = context?.workspaceState?.openFiles;
|
|
@@ -83365,7 +83408,7 @@ async function getIdeStatusMessageWithFiles(ideClient) {
|
|
|
83365
83408
|
content
|
|
83366
83409
|
};
|
|
83367
83410
|
}
|
|
83368
|
-
case
|
|
83411
|
+
case IDEConnectionStatus.Connecting:
|
|
83369
83412
|
return {
|
|
83370
83413
|
messageType: "info",
|
|
83371
83414
|
content: `\u{1F7E1} Connecting...`
|
|
@@ -83387,7 +83430,7 @@ async function setIdeModeAndSyncConnection(config, value, options = {}) {
|
|
|
83387
83430
|
const ideClient = await IdeClient.getInstance();
|
|
83388
83431
|
if (value) {
|
|
83389
83432
|
await ideClient.connect(options);
|
|
83390
|
-
logIdeConnection(config, new IdeConnectionEvent(
|
|
83433
|
+
logIdeConnection(config, new IdeConnectionEvent(IdeConnectionType.SESSION));
|
|
83391
83434
|
} else {
|
|
83392
83435
|
await ideClient.disconnect();
|
|
83393
83436
|
}
|
|
@@ -83475,7 +83518,7 @@ var ideCommand = async () => {
|
|
|
83475
83518
|
logToConsole: false
|
|
83476
83519
|
}
|
|
83477
83520
|
);
|
|
83478
|
-
if (ideClient.getConnectionStatus().status ===
|
|
83521
|
+
if (ideClient.getConnectionStatus().status === IDEConnectionStatus.Connected) {
|
|
83479
83522
|
break;
|
|
83480
83523
|
}
|
|
83481
83524
|
await new Promise((resolve9) => setTimeout(resolve9, 500));
|
|
@@ -83552,7 +83595,7 @@ var ideCommand = async () => {
|
|
|
83552
83595
|
}
|
|
83553
83596
|
};
|
|
83554
83597
|
const { status } = ideClient.getConnectionStatus();
|
|
83555
|
-
const isConnected = status ===
|
|
83598
|
+
const isConnected = status === IDEConnectionStatus.Connected;
|
|
83556
83599
|
if (isConnected) {
|
|
83557
83600
|
ideSlashCommand.subCommands = [statusCommand2, disableCommand5];
|
|
83558
83601
|
} else {
|
|
@@ -83652,13 +83695,13 @@ Use /mcp auth <server-name> to authenticate.`
|
|
|
83652
83695
|
const displayListener = (message) => {
|
|
83653
83696
|
context.ui.addItem({ type: "info", text: message });
|
|
83654
83697
|
};
|
|
83655
|
-
coreEvents.on(
|
|
83698
|
+
coreEvents.on(CoreEvent.OauthDisplayMessage, displayListener);
|
|
83656
83699
|
try {
|
|
83657
83700
|
context.ui.addItem({
|
|
83658
83701
|
type: "info",
|
|
83659
83702
|
text: `Starting OAuth authentication for MCP server '${serverName}'...`
|
|
83660
83703
|
});
|
|
83661
|
-
const { MCPOAuthProvider } = await import("./
|
|
83704
|
+
const { MCPOAuthProvider } = await import("./dist-KGTOLDFD.js");
|
|
83662
83705
|
let oauthConfig = server.oauth;
|
|
83663
83706
|
if (!oauthConfig) {
|
|
83664
83707
|
oauthConfig = { enabled: false };
|
|
@@ -83695,7 +83738,7 @@ Use /mcp auth <server-name> to authenticate.`
|
|
|
83695
83738
|
content: `Failed to authenticate with MCP server '${serverName}': ${getErrorMessage(error)}`
|
|
83696
83739
|
};
|
|
83697
83740
|
} finally {
|
|
83698
|
-
coreEvents.removeListener(
|
|
83741
|
+
coreEvents.removeListener(CoreEvent.OauthDisplayMessage, displayListener);
|
|
83699
83742
|
}
|
|
83700
83743
|
},
|
|
83701
83744
|
completion: async (context, partialArg) => {
|
|
@@ -83741,10 +83784,10 @@ var listAction2 = async (context, showDescriptions = false, showSchema = false,
|
|
|
83741
83784
|
}
|
|
83742
83785
|
const serverNames = Object.keys(mcpServers);
|
|
83743
83786
|
const connectingServers = serverNames.filter(
|
|
83744
|
-
(name) => getMCPServerStatus(name) ===
|
|
83787
|
+
(name) => getMCPServerStatus(name) === MCPServerStatus.CONNECTING
|
|
83745
83788
|
);
|
|
83746
83789
|
const discoveryState = getMCPDiscoveryState();
|
|
83747
|
-
const discoveryInProgress = discoveryState ===
|
|
83790
|
+
const discoveryInProgress = discoveryState === MCPDiscoveryState.IN_PROGRESS || connectingServers.length > 0;
|
|
83748
83791
|
const allTools = toolRegistry.getAllTools();
|
|
83749
83792
|
const mcpTools = allTools.filter((tool) => tool instanceof DiscoveredMCPTool);
|
|
83750
83793
|
const promptRegistry = config.getPromptRegistry();
|
|
@@ -99522,7 +99565,7 @@ Return a JSON object with:
|
|
|
99522
99565
|
},
|
|
99523
99566
|
abortSignal: new AbortController().signal,
|
|
99524
99567
|
promptId: "triage-duplicates",
|
|
99525
|
-
role:
|
|
99568
|
+
role: LlmRole.UTILITY_TOOL
|
|
99526
99569
|
});
|
|
99527
99570
|
const rec = response;
|
|
99528
99571
|
let canonical;
|
|
@@ -100356,7 +100399,7 @@ Return a JSON object with:
|
|
|
100356
100399
|
},
|
|
100357
100400
|
abortSignal: abortControllerRef.current.signal,
|
|
100358
100401
|
promptId: "triage-issues",
|
|
100359
|
-
role:
|
|
100402
|
+
role: LlmRole.UTILITY_TOOL
|
|
100360
100403
|
});
|
|
100361
100404
|
return response;
|
|
100362
100405
|
},
|
|
@@ -100930,8 +100973,8 @@ var planCommand = {
|
|
|
100930
100973
|
return;
|
|
100931
100974
|
}
|
|
100932
100975
|
const previousApprovalMode = config.getApprovalMode();
|
|
100933
|
-
config.setApprovalMode(
|
|
100934
|
-
if (previousApprovalMode !==
|
|
100976
|
+
config.setApprovalMode(ApprovalMode.PLAN);
|
|
100977
|
+
if (previousApprovalMode !== ApprovalMode.PLAN) {
|
|
100935
100978
|
coreEvents.emitFeedback("info", "Switched to Plan Mode.");
|
|
100936
100979
|
}
|
|
100937
100980
|
if (context.invocation?.args) {
|
|
@@ -100990,10 +101033,10 @@ var categorizeRulesByMode = (rules) => {
|
|
|
100990
101033
|
rules.forEach((rule) => {
|
|
100991
101034
|
const modes = rule.modes?.length ? rule.modes : ALL_MODES;
|
|
100992
101035
|
const modeSet = new Set(modes);
|
|
100993
|
-
if (modeSet.has(
|
|
100994
|
-
if (modeSet.has(
|
|
100995
|
-
if (modeSet.has(
|
|
100996
|
-
if (modeSet.has(
|
|
101036
|
+
if (modeSet.has(ApprovalMode.DEFAULT)) result.normal.push(rule);
|
|
101037
|
+
if (modeSet.has(ApprovalMode.AUTO_EDIT)) result.autoEdit.push(rule);
|
|
101038
|
+
if (modeSet.has(ApprovalMode.YOLO)) result.yolo.push(rule);
|
|
101039
|
+
if (modeSet.has(ApprovalMode.PLAN)) result.plan.push(rule);
|
|
100997
101040
|
});
|
|
100998
101041
|
return result;
|
|
100999
101042
|
};
|
|
@@ -102374,7 +102417,7 @@ var upgradeCommand = {
|
|
|
102374
102417
|
action: async (context) => {
|
|
102375
102418
|
const config = context.services.agentContext?.config;
|
|
102376
102419
|
const authType = config?.getContentGeneratorConfig()?.authType;
|
|
102377
|
-
if (authType !==
|
|
102420
|
+
if (authType !== AuthType.LOGIN_WITH_GOOGLE) {
|
|
102378
102421
|
return {
|
|
102379
102422
|
type: "message",
|
|
102380
102423
|
messageType: "error",
|
|
@@ -102603,7 +102646,7 @@ var BuiltinCommandLoader = class {
|
|
|
102603
102646
|
setupGithubCommand,
|
|
102604
102647
|
terminalSetupCommand,
|
|
102605
102648
|
...this.config?.isVoiceModeEnabled() ? [voiceCommand] : [],
|
|
102606
|
-
...this.config?.getContentGeneratorConfig()?.authType ===
|
|
102649
|
+
...this.config?.getContentGeneratorConfig()?.authType === AuthType.LOGIN_WITH_GOOGLE ? [upgradeCommand] : []
|
|
102607
102650
|
];
|
|
102608
102651
|
handle?.end();
|
|
102609
102652
|
return allDefinitions.filter((cmd) => cmd !== null);
|
|
@@ -102993,6 +103036,7 @@ export {
|
|
|
102993
103036
|
Footer,
|
|
102994
103037
|
getAntigravityInstallInfo,
|
|
102995
103038
|
build_default,
|
|
103039
|
+
TMUX_SPINNER_INTERVAL_MS,
|
|
102996
103040
|
CliSpinner,
|
|
102997
103041
|
MAX_WIDTH,
|
|
102998
103042
|
ExpandableText,
|