@google/gemini-cli 0.37.0-preview.0 → 0.37.0-preview.1
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-ULC3DHVX.js → chunk-33B2YA3V.js} +4 -4
- package/bundle/{chunk-3TN4SOLW.js → chunk-43UUP7VO.js} +72 -29
- package/bundle/{chunk-R5X4CMUM.js → chunk-5OOT636U.js} +30 -23
- package/bundle/{chunk-A62NZYIK.js → chunk-BLL44IGV.js} +71 -59
- package/bundle/{chunk-7UZ4Y32N.js → chunk-JS5WSGB2.js} +30 -23
- package/bundle/{chunk-LEK5YYAR.js → chunk-PPWUMHZT.js} +65 -28
- package/bundle/chunk-TSSVZ7RZ.js +98376 -0
- package/bundle/{chunk-TJ76C6AA.js → chunk-VSXV53B7.js} +5901 -11014
- package/bundle/{chunk-XX7JYMTE.js → chunk-WZB27TDF.js} +4 -4
- package/bundle/chunk-ZB4UQCX5.js +356418 -0
- package/bundle/{core-5OME6LT4.js → core-RMRIZ3E5.js} +4 -2
- package/bundle/{devtoolsService-TVWW3DBW.js → devtoolsService-2ULAA43E.js} +3 -3
- package/bundle/{devtoolsService-IDLWLZFQ.js → devtoolsService-AWVCG2N2.js} +5 -4
- package/bundle/devtoolsService-IWSTJYRB.js +871 -0
- package/bundle/{devtoolsService-4FIYD6OW.js → devtoolsService-SZYXXACN.js} +3 -3
- package/bundle/{core-CUCGSGCA.js → dist-4FKFY6XB.js} +4 -2
- package/bundle/{dist-YWCADMDD.js → dist-PRDBNGX2.js} +4 -2
- package/bundle/dist-TCCEQJDV.js +1942 -0
- package/bundle/docs/cli/plan-mode.md +10 -3
- package/bundle/docs/reference/policy-engine.md +20 -1
- package/bundle/gemini.js +7 -7
- package/bundle/{interactiveCli-4WFWOVAQ.js → interactiveCli-24VGI5NV.js} +4 -4
- package/bundle/{interactiveCli-6SIGBRWS.js → interactiveCli-D2MTTARB.js} +4 -4
- package/bundle/{interactiveCli-4ZZ72DR3.js → interactiveCli-DX76MWWT.js} +264 -247
- package/bundle/interactiveCli-VNDJAKWG.js +50355 -0
- package/bundle/{memoryDiscovery-NS2EGHYH.js → memoryDiscovery-A265O6ML.js} +1 -1
- package/bundle/{memoryDiscovery-VL3OH25S.js → memoryDiscovery-H6J7KIH2.js} +1 -1
- package/bundle/node_modules/@google/gemini-cli-devtools/package.json +1 -1
- package/bundle/{oauth2-provider-TYBJKXSJ.js → oauth2-provider-FZUTS3SV.js} +2 -2
- package/bundle/{oauth2-provider-HGHECKPY.js → oauth2-provider-K25DXIWC.js} +2 -2
- package/bundle/{oauth2-provider-YYRJ44X5.js → oauth2-provider-N73M7SQI.js} +39 -73
- package/bundle/oauth2-provider-RMDEEXSP.js +237 -0
- package/package.json +1 -1
|
@@ -180,9 +180,16 @@ As described in the
|
|
|
180
180
|
rule that does not explicitly specify `modes` is considered "always active" and
|
|
181
181
|
will apply to Plan Mode as well.
|
|
182
182
|
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
183
|
+
To maintain the integrity of Plan Mode as a safe research environment,
|
|
184
|
+
persistent tool approvals are context-aware. Approvals granted in modes like
|
|
185
|
+
Default or Auto-Edit do not apply to Plan Mode, ensuring that tools trusted for
|
|
186
|
+
implementation don't automatically execute while you're researching. However,
|
|
187
|
+
approvals granted while in Plan Mode are treated as intentional choices for
|
|
188
|
+
global trust and apply to all modes.
|
|
189
|
+
|
|
190
|
+
If you want to manually restrict a rule to other modes but _not_ to Plan Mode,
|
|
191
|
+
you must explicitly specify the target modes. For example, to allow `npm test`
|
|
192
|
+
in default and Auto-Edit modes but not in Plan Mode:
|
|
186
193
|
|
|
187
194
|
```toml
|
|
188
195
|
[[rule]]
|
|
@@ -171,6 +171,24 @@ modes specified, it is always active.
|
|
|
171
171
|
[Customizing Plan Mode Policies](../cli/plan-mode.md#customizing-policies).
|
|
172
172
|
- `yolo`: A mode where all tools are auto-approved (use with extreme caution).
|
|
173
173
|
|
|
174
|
+
To maintain the integrity of Plan Mode as a safe research environment,
|
|
175
|
+
persistent tool approvals are context-aware. When you select **"Allow for all
|
|
176
|
+
future sessions"**, the policy engine explicitly includes the current mode and
|
|
177
|
+
all more permissive modes in the hierarchy (`plan` < `default` < `autoEdit` <
|
|
178
|
+
`yolo`).
|
|
179
|
+
|
|
180
|
+
- **Approvals in `plan` mode**: These represent an intentional choice to trust a
|
|
181
|
+
tool globally. The resulting rule explicitly includes all modes (`plan`,
|
|
182
|
+
`default`, `autoEdit`, and `yolo`).
|
|
183
|
+
- **Approvals in other modes**: These only apply to the current mode and those
|
|
184
|
+
more permissive. For example:
|
|
185
|
+
- An approval granted in **`default`** mode applies to `default`, `autoEdit`,
|
|
186
|
+
and `yolo`.
|
|
187
|
+
- An approval granted in **`autoEdit`** mode applies to `autoEdit` and `yolo`.
|
|
188
|
+
- An approval granted in **`yolo`** mode applies only to `yolo`. This ensures
|
|
189
|
+
that trust flows correctly to more permissive environments while maintaining
|
|
190
|
+
the safety of more restricted modes like `plan`.
|
|
191
|
+
|
|
174
192
|
## Rule matching
|
|
175
193
|
|
|
176
194
|
When a tool call is made, the engine checks it against all active rules,
|
|
@@ -304,7 +322,8 @@ priority = 10
|
|
|
304
322
|
denyMessage = "Deletion is permanent"
|
|
305
323
|
|
|
306
324
|
# (Optional) An array of approval modes where this rule is active.
|
|
307
|
-
|
|
325
|
+
# If omitted or empty, the rule applies to all modes.
|
|
326
|
+
modes = ["default", "autoEdit", "yolo"]
|
|
308
327
|
|
|
309
328
|
# (Optional) A boolean to restrict the rule to interactive (true) or
|
|
310
329
|
# non-interactive (false) environments.
|
package/bundle/gemini.js
CHANGED
|
@@ -66,7 +66,7 @@ import {
|
|
|
66
66
|
updateAllUpdatableExtensions,
|
|
67
67
|
updateExtension,
|
|
68
68
|
validateAuthMethod
|
|
69
|
-
} from "./chunk-
|
|
69
|
+
} from "./chunk-TSSVZ7RZ.js";
|
|
70
70
|
import {
|
|
71
71
|
AuthType,
|
|
72
72
|
ChatRecordingService,
|
|
@@ -155,7 +155,7 @@ import {
|
|
|
155
155
|
updatePolicy,
|
|
156
156
|
writeToStderr,
|
|
157
157
|
writeToStdout
|
|
158
|
-
} from "./chunk-
|
|
158
|
+
} from "./chunk-ZB4UQCX5.js";
|
|
159
159
|
import {
|
|
160
160
|
ASK_USER_TOOL_NAME,
|
|
161
161
|
ApprovalMode,
|
|
@@ -201,7 +201,7 @@ import {
|
|
|
201
201
|
loadServerHierarchicalMemory,
|
|
202
202
|
resolveToRealPath,
|
|
203
203
|
setGeminiMdFilename
|
|
204
|
-
} from "./chunk-
|
|
204
|
+
} from "./chunk-JS5WSGB2.js";
|
|
205
205
|
import "./chunk-664ZODQF.js";
|
|
206
206
|
import {
|
|
207
207
|
appEvents
|
|
@@ -7251,7 +7251,7 @@ async function loadSandboxConfig(settings, argv) {
|
|
|
7251
7251
|
}
|
|
7252
7252
|
const command2 = getSandboxCommand(sandboxValue);
|
|
7253
7253
|
const packageJson = await getPackageJson(__dirname3);
|
|
7254
|
-
const image = process.env["GEMINI_SANDBOX_IMAGE"] ?? "us-docker.pkg.dev/gemini-code-dev/gemini-cli/sandbox:0.37.0-preview.
|
|
7254
|
+
const image = process.env["GEMINI_SANDBOX_IMAGE"] ?? "us-docker.pkg.dev/gemini-code-dev/gemini-cli/sandbox:0.37.0-preview.1" ?? customImage ?? packageJson?.config?.sandboxImageUri;
|
|
7255
7255
|
const isNative = command2 === "windows-native" || command2 === "sandbox-exec" || command2 === "lxc";
|
|
7256
7256
|
return command2 && (image || isNative) ? { enabled: true, allowedPaths, networkAccess, command: command2, image } : void 0;
|
|
7257
7257
|
}
|
|
@@ -9539,7 +9539,7 @@ async function runNonInteractive({
|
|
|
9539
9539
|
}
|
|
9540
9540
|
});
|
|
9541
9541
|
if (process.env["GEMINI_CLI_ACTIVITY_LOG_TARGET"]) {
|
|
9542
|
-
const { setupInitialActivityLogger } = await import("./devtoolsService-
|
|
9542
|
+
const { setupInitialActivityLogger } = await import("./devtoolsService-IWSTJYRB.js");
|
|
9543
9543
|
await setupInitialActivityLogger(config);
|
|
9544
9544
|
}
|
|
9545
9545
|
const { stdout: workingStdout } = createWorkingStdio();
|
|
@@ -14263,7 +14263,7 @@ ${reason.stack}` : ""}`;
|
|
|
14263
14263
|
});
|
|
14264
14264
|
}
|
|
14265
14265
|
async function startInteractiveUI(config, settings, startupWarnings, workspaceRoot = process.cwd(), resumedSessionData, initializationResult) {
|
|
14266
|
-
const { startInteractiveUI: doStartUI } = await import("./interactiveCli-
|
|
14266
|
+
const { startInteractiveUI: doStartUI } = await import("./interactiveCli-DX76MWWT.js");
|
|
14267
14267
|
await doStartUI(
|
|
14268
14268
|
config,
|
|
14269
14269
|
settings,
|
|
@@ -14460,7 +14460,7 @@ ${finalArgs[promptIndex + 1]}`;
|
|
|
14460
14460
|
await config.storage.initialize();
|
|
14461
14461
|
adminControlsListner.setConfig(config);
|
|
14462
14462
|
if (config.isInteractive() && settings.merged.general.devtools) {
|
|
14463
|
-
const { setupInitialActivityLogger } = await import("./devtoolsService-
|
|
14463
|
+
const { setupInitialActivityLogger } = await import("./devtoolsService-IWSTJYRB.js");
|
|
14464
14464
|
await setupInitialActivityLogger(config);
|
|
14465
14465
|
}
|
|
14466
14466
|
registerTelemetryConfig(config);
|
|
@@ -186,7 +186,7 @@ import {
|
|
|
186
186
|
widestLineFromStyledChars,
|
|
187
187
|
wordBreakStyledChars,
|
|
188
188
|
wrapStyledChars
|
|
189
|
-
} from "./chunk-
|
|
189
|
+
} from "./chunk-BLL44IGV.js";
|
|
190
190
|
import {
|
|
191
191
|
ApiKeyUpdatedEvent,
|
|
192
192
|
AsyncFzf,
|
|
@@ -306,7 +306,7 @@ import {
|
|
|
306
306
|
validatePlanContent,
|
|
307
307
|
validatePlanPath,
|
|
308
308
|
writeToStdout
|
|
309
|
-
} from "./chunk-
|
|
309
|
+
} from "./chunk-VSXV53B7.js";
|
|
310
310
|
import {
|
|
311
311
|
ACTIVATE_SKILL_TOOL_NAME,
|
|
312
312
|
ApprovalMode,
|
|
@@ -371,7 +371,7 @@ import {
|
|
|
371
371
|
safeJsonToMarkdown,
|
|
372
372
|
shortenPath,
|
|
373
373
|
tildeifyPath
|
|
374
|
-
} from "./chunk-
|
|
374
|
+
} from "./chunk-JS5WSGB2.js";
|
|
375
375
|
import "./chunk-664ZODQF.js";
|
|
376
376
|
import {
|
|
377
377
|
appEvents
|
|
@@ -49406,7 +49406,7 @@ ${queuedText}` : queuedText;
|
|
|
49406
49406
|
if (keyMatchers["app.showErrorDetails" /* SHOW_ERROR_DETAILS */](key)) {
|
|
49407
49407
|
if (settings.merged.general.devtools) {
|
|
49408
49408
|
void (async () => {
|
|
49409
|
-
const { toggleDevToolsPanel } = await import("./devtoolsService-
|
|
49409
|
+
const { toggleDevToolsPanel } = await import("./devtoolsService-2ULAA43E.js");
|
|
49410
49410
|
await toggleDevToolsPanel(
|
|
49411
49411
|
config,
|
|
49412
49412
|
showErrorDetails,
|
|
@@ -186,7 +186,7 @@ import {
|
|
|
186
186
|
widestLineFromStyledChars,
|
|
187
187
|
wordBreakStyledChars,
|
|
188
188
|
wrapStyledChars
|
|
189
|
-
} from "./chunk-
|
|
189
|
+
} from "./chunk-WZB27TDF.js";
|
|
190
190
|
import {
|
|
191
191
|
ApiKeyUpdatedEvent,
|
|
192
192
|
AsyncFzf,
|
|
@@ -296,7 +296,7 @@ import {
|
|
|
296
296
|
validatePlanContent,
|
|
297
297
|
validatePlanPath,
|
|
298
298
|
writeToStdout
|
|
299
|
-
} from "./chunk-
|
|
299
|
+
} from "./chunk-43UUP7VO.js";
|
|
300
300
|
import {
|
|
301
301
|
ACTIVATE_SKILL_TOOL_NAME,
|
|
302
302
|
ChangeAuthRequestedError,
|
|
@@ -354,7 +354,7 @@ import {
|
|
|
354
354
|
safeJsonToMarkdown,
|
|
355
355
|
shortenPath,
|
|
356
356
|
tildeifyPath
|
|
357
|
-
} from "./chunk-
|
|
357
|
+
} from "./chunk-5OOT636U.js";
|
|
358
358
|
import "./chunk-664ZODQF.js";
|
|
359
359
|
import {
|
|
360
360
|
appEvents
|
|
@@ -49389,7 +49389,7 @@ ${queuedText}` : queuedText;
|
|
|
49389
49389
|
if (keyMatchers["app.showErrorDetails" /* SHOW_ERROR_DETAILS */](key)) {
|
|
49390
49390
|
if (settings.merged.general.devtools) {
|
|
49391
49391
|
void (async () => {
|
|
49392
|
-
const { toggleDevToolsPanel } = await import("./devtoolsService-
|
|
49392
|
+
const { toggleDevToolsPanel } = await import("./devtoolsService-SZYXXACN.js");
|
|
49393
49393
|
await toggleDevToolsPanel(
|
|
49394
49394
|
config,
|
|
49395
49395
|
showErrorDetails,
|