@google/gemini-cli 0.36.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.
Files changed (74) hide show
  1. package/bundle/{chunk-UNM3DGTG.js → chunk-33B2YA3V.js} +711 -240
  2. package/bundle/{chunk-2OFO4ODK.js → chunk-43UUP7VO.js} +6717 -4203
  3. package/bundle/{chunk-MYI75E6G.js → chunk-5OOT636U.js} +262 -92
  4. package/bundle/{chunk-GHJNEZXJ.js → chunk-BLL44IGV.js} +777 -294
  5. package/bundle/{chunk-S2IQOR7T.js → chunk-JS5WSGB2.js} +243 -88
  6. package/bundle/{chunk-QVTX2M5J.js → chunk-PPWUMHZT.js} +6355 -4117
  7. package/bundle/chunk-TSSVZ7RZ.js +98376 -0
  8. package/bundle/chunk-U4FACSVX.js +30 -0
  9. package/bundle/{chunk-VB55KQW3.js → chunk-VSXV53B7.js} +11735 -14377
  10. package/bundle/{chunk-EAXTBDLN.js → chunk-WZB27TDF.js} +711 -240
  11. package/bundle/chunk-ZB4UQCX5.js +356418 -0
  12. package/bundle/{core-6V2OYDRU.js → core-RMRIZ3E5.js} +60 -4
  13. package/bundle/{devtoolsService-ZKU2HLK2.js → devtoolsService-2ULAA43E.js} +20 -3
  14. package/bundle/{devtoolsService-UL6JE436.js → devtoolsService-AWVCG2N2.js} +22 -4
  15. package/bundle/devtoolsService-IWSTJYRB.js +871 -0
  16. package/bundle/{devtoolsService-QTW7GHQP.js → devtoolsService-SZYXXACN.js} +20 -3
  17. package/bundle/{core-BMLL5RF4.js → dist-4FKFY6XB.js} +60 -4
  18. package/bundle/{dist-PYC2JXAJ.js → dist-PRDBNGX2.js} +60 -4
  19. package/bundle/dist-TCCEQJDV.js +1942 -0
  20. package/bundle/docs/CONTRIBUTING.md +10 -7
  21. package/bundle/docs/assets/theme-tokyonight-dark.png +0 -0
  22. package/bundle/docs/changelogs/index.md +24 -0
  23. package/bundle/docs/changelogs/latest.md +366 -459
  24. package/bundle/docs/changelogs/preview.md +362 -356
  25. package/bundle/docs/cli/acp-mode.md +126 -0
  26. package/bundle/docs/cli/cli-reference.md +1 -1
  27. package/bundle/docs/cli/notifications.md +5 -5
  28. package/bundle/docs/cli/plan-mode.md +22 -11
  29. package/bundle/docs/cli/sandbox.md +1 -1
  30. package/bundle/docs/cli/settings.md +14 -13
  31. package/bundle/docs/cli/themes.md +5 -0
  32. package/bundle/docs/core/index.md +2 -2
  33. package/bundle/docs/core/subagents.md +134 -23
  34. package/bundle/docs/get-started/gemini-3.md +1 -1
  35. package/bundle/docs/get-started/index.md +127 -1
  36. package/bundle/docs/ide-integration/index.md +99 -24
  37. package/bundle/docs/index.md +0 -2
  38. package/bundle/docs/redirects.json +1 -0
  39. package/bundle/docs/reference/commands.md +1 -3
  40. package/bundle/docs/reference/configuration.md +182 -91
  41. package/bundle/docs/reference/keyboard-shortcuts.md +14 -6
  42. package/bundle/docs/reference/policy-engine.md +36 -31
  43. package/bundle/docs/reference/tools.md +56 -23
  44. package/bundle/docs/resources/quota-and-pricing.md +23 -9
  45. package/bundle/docs/sidebar.json +11 -4
  46. package/bundle/docs/tools/planning.md +6 -4
  47. package/bundle/events-CLX3JQHP.js +12 -0
  48. package/bundle/gemini.js +342 -52
  49. package/bundle/{interactiveCli-VLQHRXHU.js → interactiveCli-24VGI5NV.js} +5066 -4010
  50. package/bundle/{interactiveCli-A6HZ2TDO.js → interactiveCli-D2MTTARB.js} +5066 -4010
  51. package/bundle/{interactiveCli-DWMSDCKV.js → interactiveCli-DX76MWWT.js} +5296 -4223
  52. package/bundle/interactiveCli-VNDJAKWG.js +50355 -0
  53. package/bundle/{memoryDiscovery-BQGYT4OD.js → memoryDiscovery-A265O6ML.js} +3 -1
  54. package/bundle/{memoryDiscovery-FCEPFZ3M.js → memoryDiscovery-H6J7KIH2.js} +3 -1
  55. package/bundle/node_modules/@google/gemini-cli-devtools/dist/client/main.js +26 -19
  56. package/bundle/node_modules/@google/gemini-cli-devtools/dist/src/_client-assets.d.ts +1 -1
  57. package/bundle/node_modules/@google/gemini-cli-devtools/dist/src/_client-assets.js +1 -1
  58. package/bundle/node_modules/@google/gemini-cli-devtools/dist/src/_client-assets.js.map +1 -1
  59. package/bundle/node_modules/@google/gemini-cli-devtools/dist/src/index.js +35 -1
  60. package/bundle/node_modules/@google/gemini-cli-devtools/dist/src/index.js.map +1 -1
  61. package/bundle/node_modules/@google/gemini-cli-devtools/package.json +1 -1
  62. package/bundle/{oauth2-provider-5ENESIRQ.js → oauth2-provider-FZUTS3SV.js} +2 -2
  63. package/bundle/{oauth2-provider-CAKFQRQV.js → oauth2-provider-K25DXIWC.js} +2 -2
  64. package/bundle/{oauth2-provider-RVED6DAZ.js → oauth2-provider-N73M7SQI.js} +39 -73
  65. package/bundle/oauth2-provider-RMDEEXSP.js +237 -0
  66. package/bundle/policies/discovered.toml +7 -0
  67. package/bundle/policies/non-interactive.toml +7 -0
  68. package/bundle/policies/plan.toml +25 -0
  69. package/bundle/policies/read-only.toml +6 -0
  70. package/bundle/policies/sandbox-default.toml +3 -2
  71. package/bundle/policies/write.toml +21 -0
  72. package/bundle/policies/yolo.toml +1 -1
  73. package/package.json +1 -1
  74. package/bundle/docs/get-started/examples.md +0 -141
@@ -7,13 +7,14 @@ allowOverrides = false
7
7
  [modes.default]
8
8
  network = false
9
9
  readonly = true
10
- approvedTools = []
10
+ approvedTools = ['cat', 'ls', 'grep', 'head', 'tail', 'less', 'Get-Content', 'dir', 'type', 'findstr', 'Get-ChildItem', 'echo']
11
11
  allowOverrides = true
12
12
 
13
13
  [modes.accepting_edits]
14
14
  network = false
15
15
  readonly = false
16
- approvedTools = ['sed', 'grep', 'awk', 'perl', 'cat', 'echo']
16
+ approvedTools = ['sed', 'grep', 'awk', 'perl', 'cat', 'echo', 'Add-Content', 'Set-Content']
17
17
  allowOverrides = true
18
18
 
19
19
  [commands]
20
+
@@ -31,6 +31,7 @@
31
31
  toolName = "replace"
32
32
  decision = "ask_user"
33
33
  priority = 10
34
+ interactive = true
34
35
 
35
36
  [[rule]]
36
37
  toolName = "replace"
@@ -47,21 +48,25 @@ required_context = ["environment"]
47
48
  toolName = "save_memory"
48
49
  decision = "ask_user"
49
50
  priority = 10
51
+ interactive = true
50
52
 
51
53
  [[rule]]
52
54
  toolName = "run_shell_command"
53
55
  decision = "ask_user"
54
56
  priority = 10
57
+ interactive = true
55
58
 
56
59
  [[rule]]
57
60
  toolName = "write_file"
58
61
  decision = "ask_user"
59
62
  priority = 10
63
+ interactive = true
60
64
 
61
65
  [[rule]]
62
66
  toolName = "activate_skill"
63
67
  decision = "ask_user"
64
68
  priority = 10
69
+ interactive = true
65
70
 
66
71
  [[rule]]
67
72
  toolName = "write_file"
@@ -84,3 +89,19 @@ modes = ["autoEdit"]
84
89
  toolName = "web_fetch"
85
90
  decision = "ask_user"
86
91
  priority = 10
92
+ interactive = true
93
+
94
+ # Headless Denial Rule (Priority 10)
95
+ # Ensures that tools that normally default to ASK_USER are denied in non-interactive mode.
96
+ [[rule]]
97
+ toolName = [
98
+ "replace",
99
+ "save_memory",
100
+ "run_shell_command",
101
+ "write_file",
102
+ "activate_skill",
103
+ "web_fetch"
104
+ ]
105
+ decision = "deny"
106
+ priority = 10
107
+ interactive = false
@@ -30,12 +30,12 @@
30
30
 
31
31
  # Ask-user tool always requires user interaction, even in YOLO mode.
32
32
  # This ensures the model can gather user preferences/decisions when needed.
33
- # Note: In non-interactive mode, this decision is converted to DENY by the policy engine.
34
33
  [[rule]]
35
34
  toolName = "ask_user"
36
35
  decision = "ask_user"
37
36
  priority = 999
38
37
  modes = ["yolo"]
38
+ interactive = true
39
39
 
40
40
  # Plan mode transitions are blocked in YOLO mode to maintain state consistency
41
41
  # and because planning currently requires human interaction (plan approval),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@google/gemini-cli",
3
- "version": "0.36.0",
3
+ "version": "0.37.0-preview.1",
4
4
  "description": "Gemini CLI",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -1,141 +0,0 @@
1
- # Gemini CLI examples
2
-
3
- Gemini CLI helps you automate common engineering tasks by combining AI reasoning
4
- with local system tools. This document provides examples of how to use the CLI
5
- for file management, code analysis, and data transformation.
6
-
7
- <!-- prettier-ignore -->
8
- > [!NOTE]
9
- > These examples demonstrate potential capabilities. Your actual
10
- > results can vary based on the model used and your project environment.
11
-
12
- ## Rename your photographs based on content
13
-
14
- You can use Gemini CLI to automate file management tasks that require visual
15
- analysis. In this example, Gemini CLI renames images based on their actual
16
- subject matter.
17
-
18
- Scenario: You have a folder containing the following files:
19
-
20
- ```bash
21
- photos/photo1.png
22
- photos/photo2.png
23
- photos/photo3.png
24
- ```
25
-
26
- Give Gemini the following prompt:
27
-
28
- ```cli
29
- Rename the photos in my "photos" directory based on their contents.
30
- ```
31
-
32
- Result: Gemini asks for permission to rename your files.
33
-
34
- Select **Allow once** and your files are renamed:
35
-
36
- ```bash
37
- photos/yellow_flowers.png
38
- photos/antique_dresser.png
39
- photos/green_android_robot.png
40
- ```
41
-
42
- ## Explain a repository by reading its code
43
-
44
- Gemini CLI is effective for rapid codebase exploration. The following example
45
- shows how to ask Gemini CLI to fetch, analyze, and summarize a remote project.
46
-
47
- Scenario: You want to understand how a popular open-source utility works by
48
- inspecting its code, not just its README.
49
-
50
- Give Gemini CLI the following prompt:
51
-
52
- ```cli
53
- Clone the 'chalk' repository from https://github.com/chalk/chalk, read its key source files, and explain how it works.
54
- ```
55
-
56
- Result: Gemini performs a sequence of actions to answer your request.
57
-
58
- 1. First, it asks for permission to run `git clone` to download the repository.
59
- 2. Next, it finds the important source files and asks for permission to read
60
- them.
61
- 3. Finally, after analyzing the code, it provides a summary.
62
-
63
- Gemini CLI returns an explanation based on the actual source code:
64
-
65
- ```markdown
66
- The `chalk` library is a popular npm package for styling terminal output with
67
- colors. After analyzing the source code, here's how it works:
68
-
69
- - **Core functionality:** The main file sets up a chainable API. Each color or
70
- modifier (like `bold` or `italic`) is a getter that appends the corresponding
71
- ANSI escape code to an internal stack.
72
-
73
- - **Chainable API:** When you call `chalk.red.bold('Hello')`, you are accessing
74
- getters. The `red` getter adds the red color code, and the `bold` getter adds
75
- the bold code.
76
-
77
- - **Output generation:** When the chain is treated as a string (e.g., in
78
- `console.log`), a final `toString()` method is called. This method joins all
79
- the stored ANSI codes, wraps them around the input string ('Hello'), and adds
80
- a reset code at the end. This produces the final, styled string that the
81
- terminal can render.
82
- ```
83
-
84
- ## Combine two spreadsheets into one spreadsheet
85
-
86
- Gemini CLI can process and transform data across multiple files. Use this
87
- capability to merge reports or reformat data sets without manual copying.
88
-
89
- Scenario: You have two .csv files: `Revenue - 2023.csv` and
90
- `Revenue - 2024.csv`. Each file contains monthly revenue figures.
91
-
92
- Give Gemini CLI the following prompt:
93
-
94
- ```cli
95
- Combine the two .csv files into a single .csv file, with each year a different column.
96
- ```
97
-
98
- Result: Gemini CLI reads each file and then asks for permission to write a new
99
- file. Provide your permission and Gemini CLI provides the combined data:
100
-
101
- ```csv
102
- Month,2023,2024
103
- January,0,1000
104
- February,0,1200
105
- March,0,2400
106
- April,900,500
107
- May,1000,800
108
- June,1000,900
109
- July,1200,1000
110
- August,1800,400
111
- September,2000,2000
112
- October,2400,3400
113
- November,3400,1800
114
- December,2100,9000
115
- ```
116
-
117
- ## Run unit tests
118
-
119
- Gemini CLI can generate boilerplate code and tests based on your existing
120
- implementation. This example demonstrates how to request code coverage for a
121
- JavaScript component.
122
-
123
- Scenario: You've written a simple login page. You wish to write unit tests to
124
- ensure that your login page has code coverage.
125
-
126
- Give Gemini CLI the following prompt:
127
-
128
- ```cli
129
- Write unit tests for Login.js.
130
- ```
131
-
132
- Result: Gemini CLI asks for permission to write a new file and creates a test
133
- for your login page.
134
-
135
- ## Next steps
136
-
137
- - Follow the [File management](../cli/tutorials/file-management.md) guide to
138
- start working with your codebase.
139
- - Follow the [Quickstart](./index.md) to start your first session.
140
- - See the [Cheatsheet](../cli/cli-reference.md) for a quick reference of
141
- available commands.