Commit Graph

69 Commits

Author SHA1 Message Date
Tommaso Sciortino
a866e2ac68 Make glob tool support abortSignal (#988) 2025-06-12 13:27:40 -07:00
dependabot[bot]
9f7aafde17 chore(deps-dev): bump esbuild from 0.23.1 to 0.25.0 (#872)
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-12 06:21:50 +00:00
Louis Jimenez
b19571d9ab Restore Checkpoint Feature (#934) 2025-06-11 15:33:09 -04:00
Tommaso Sciortino
1368f30b11 Register dependency added in PR:910 (#925) 2025-06-10 20:39:29 -07:00
Tommaso Sciortino
93cd4e20ab Basic code assist support (#910) 2025-06-10 16:00:13 -07:00
Olcan
42f146f820 restricted networking for all sandboxing methods, new seatbelt profiles, updated docs, fixes to sandbox build, debugging through sandbox (#891) 2025-06-10 08:58:37 -07:00
matt korwel
920aa861cf Windows: Refactor Shell Scripts to Node.js for Cross-Platform Compatibility (#784) 2025-06-09 12:19:42 -07:00
Abhi
8778942e11 Bump @google/genai dependency (#870) 2025-06-09 14:17:39 -04:00
matt korwel
b2cbdf3091 Rollforward AST changes to unblock Sandboxing (#863) 2025-06-08 19:07:25 -07:00
N. Taylor Mullen
275c295dc3 feat(git): Refactor gitignore handling to use ignore library instead of minimatch (#864) 2025-06-08 18:32:19 -07:00
matt korwel
334a7e0070 fix(deps): externalize tree-sitter (#840)
Submitting without approval to fix broken deployment on main. But also, we should lock this down.
2025-06-08 02:05:55 -07:00
cperry-goog
a49f734c13 refactor: rename gemini-code to gemini-cli (#822) 2025-06-07 14:27:22 -07:00
matt korwel
d749c1c429 Creating Node AST Tool. (#756) 2025-06-07 12:07:58 -07:00
Jerop Kipruto
d0de44824f OpenTelemetry Integration & Telemetry Control Flag (#762) 2025-06-05 13:04:25 -07:00
Eddie Santos
9a7199519e Add support for .geminiignore file (#757) 2025-06-05 10:15:27 -07:00
anj-s
91abea3419 Checks for diff changes before displaying the code snippet (#751) 2025-06-05 06:48:03 -07:00
Keith Ballinger
906f716d3e Ignore folders files (#651)
# Add .gitignore-Aware File Filtering to gemini-cli

This pull request introduces .gitignore-based file filtering to the gemini-cli, ensuring that git-ignored files are automatically excluded from file-related operations and suggestions throughout the CLI. The update enhances usability, reduces noise from build artifacts and dependencies, and provides new configuration options for fine-tuning file discovery.

Key Improvements
.gitignore File Filtering

All @ (at) commands, file completions, and core discovery tools now honor .gitignore patterns by default.
Git-ignored files (such as node_modules/, dist/, .env, and .git) are excluded from results unless explicitly overridden.
The behavior can be customized via a new fileFiltering section in settings.json, including options for:
Turning .gitignore respect on/off.
Adding custom ignore patterns.
Allowing or excluding build artifacts.
Configuration & Documentation Updates

settings.json schema extended with fileFiltering options.
Documentation updated to explain new filtering controls and usage patterns.
Testing

New and updated integration/unit tests for file filtering logic, configuration merging, and edge cases.
Test coverage ensures .gitignore filtering works as intended across different workflows.
Internal Refactoring

Core file discovery logic refactored for maintainability and extensibility.
Underlying tools (ls, glob, read-many-files) now support git-aware filtering out of the box.


Co-authored-by: N. Taylor Mullen <ntaylormullen@google.com>
2025-06-04 04:40:46 +00:00
N. Taylor Mullen
49fd7786f0 Update package-lock.json (#738) 2025-06-04 04:05:39 +00:00
Olcan
9752b7fb07 fixed strip-ansi dep by installing it in core package (also ran npm install in cli package that resulted in the minor changes here) (#727) 2025-06-03 13:37:59 -07:00
N. Taylor Mullen
c4e6677821 feat: Refactor CLI header for customizable logo text (#658) 2025-06-02 11:45:09 -07:00
Allen Hutchison
b78c320cbd feat: allow custom filename for context files (#654)
Co-authored-by: N. Taylor Mullen <ntaylormullen@google.com>
2025-05-31 12:49:28 -07:00
Tommaso Sciortino
64bd136f42 Rename server->core (#638) 2025-05-30 18:25:47 -07:00
Olcan
05cebe09c7 use npx json instead of jq (#617) 2025-05-30 01:12:36 -07:00
Brandon Keiji
12dbd1307a fix: publish @gemini-code/server (#605) 2025-05-29 23:55:34 +00:00
Brandon Keiji
71f2dcd0f1 feat: add git branch name to footer (#589) 2025-05-28 16:30:05 -07:00
Taylor Mullen
eba3a19ce8 feat: Replace SQLite with JSON logging for macOS sandbox compatibility
- Removes the sqlite3 dependency and refactors the logging mechanism to use a JSON file (logs.json) instead of a database.
- This change is a temporary workaround to address issues with macOS sandboxing that were caused by the SQLite native module.
- Storing all logs in a single JSON file may introduce scalability concerns in the future.

Fixes https://github.com/google-gemini/gemini-cli/issues/522
2025-05-26 16:13:37 -07:00
Taylor Mullen
b02b5bb3c8 Chore(deps): Upgrade @google/genai to v1.0.1
- Upgraded the @google/genai SDK from ^0.13.0 to ^1.0.1.
- Addressed a related type error in `packages/server/src/tools/edit.test.ts` by updating a type assertion.

Part of https://github.com/google-gemini/gemini-cli/issues/551
2025-05-26 14:09:43 -07:00
Taylor Mullen
e68c69594e fix: Update dependencies to resolve deprecation warnings 2025-05-23 14:50:00 -07:00
Taylor Mullen
870adc521d feat: Enable npx execution directly from GitHub URL
This commit modifies the packaging setup to allow the CLI to be
executed directly from its GitHub URL using `npx`, for example:
`npx https://github.com/google-gemini/gemini-cli` (once merged to main).
This is achieved without requiring the bundle to be checked into
the repository.

Key changes and motivations:

- Modify `scripts.prepare` to run `npm run bundle`:
  Ensures the CLI bundle is generated automatically when `npx`
  installs the package from a git URL. This replaces previous
  approaches (e.g., using `prepack`) which were not consistently
  triggered in the `npx` environment.

- Update `scripts.bundle` to use a direct path for `esbuild`
  and externalize `sqlite3`:
  Using `node_modules/.bin/esbuild` provides a more reliable way
  to invoke the bundler. Externalizing `sqlite3` is crucial for
  correctly handling its native addon, preventing runtime errors.

- Add `bin`, `files`, and root `sqlite3` dependency:
  - The `bin` field defines the `gemini` command.
  - The `files` array ensures the generated `bundle/` directory is
    recognized by npm.
  - `sqlite3` is added as a root dependency to ensure it's
    installed by `npx` when `gemini-code` is fetched, allowing the
    externalized module to be resolved.

These changes collectively ensure that the necessary build artifacts
are created on-the-fly during `npx` installation, providing a
seamless execution experience directly from the GitHub repository URL.
2025-05-23 13:55:06 -07:00
Brandon Keiji
2b61d08dff feat: add emphasis to tool confirmations (#502) 2025-05-23 05:28:31 +00:00
Allen Hutchison
b0075bacba Feat: Add test coverage scripts and ignore reports (#477) 2025-05-21 17:03:22 -07:00
Seth Troisi
d913d44981 Add Logger for command history (#435) 2025-05-21 00:36:22 -07:00
Jacob Richman
042b85a4dc Support Images and PDFs (#447) 2025-05-20 13:02:41 -07:00
Allen Hutchison
6233a0b390 feat(cli): Implement /bug command and add open dependency (#428) 2025-05-19 16:56:32 -07:00
olcan
8e753fda6a allow comments in settings.json 2025-05-18 10:58:20 -07:00
Jacob Richman
56dcfa4e3a strip escape characters when pasting. (#386) 2025-05-16 13:17:48 -07:00
Jacob Richman
e54a085df9 Support auto wrapping of in the multiline editor. (#383) 2025-05-16 11:58:37 -07:00
Taylor Mullen
7012c97710 fix: Ensure filename is available for diff rendering in write-file
This commit resolves a bug where the `write-file` operation could fail to render content due to a missing filename.

The fix involves:
- Ensuring `fileName` is consistently passed to `DiffRenderer.tsx` through `ToolConfirmationMessage.tsx`, `ToolMessage.tsx`, and `useGeminiStream.ts`.
- Modifying `edit.ts` and `write-file.ts` to include `fileName` in the `FileDiff` object.
- Expanding the `FileDiff` interface in `tools.ts` to include `fileName`.

Additionally, this commit enhances the diff rendering by:
- Adding syntax highlighting based on file extension in `DiffRenderer.tsx`.
- Adding more language mappings to `getLanguageFromExtension` in `DiffRenderer.tsx`.
- Added lots of tests for all the above.

Fixes https://b.corp.google.com/issues/418125982
2025-05-16 10:13:13 -07:00
Brandon Keiji
e8c774cb6c fix: remove gemini-code bin configuration (#330) 2025-05-13 13:09:58 -07:00
Taylor Mullen
4cf345d0a3 Add bundling support.
- This can now be invoked with `npm run bundle`, it creates a `bundle/` folder that has:
  - gemini.js
  - sandbox-macos-minimal.sb
  - sandbox-macos-strict.sb
  - shell.json
  - shell.md

- This doesn't include any sort of automation for auto bundling pieces. It's just the root capability which we can weave into other locations.

Fixes https://b.corp.google.com/issues/411432723
2025-05-08 23:36:42 -07:00
Taylor Mullen
9d9f7739b7 Continue to work through 429/500s.
- The root of this issue was actually a genai SDK bug that was fixed here: https://critique.corp.google.com/cl/753255997
- Upgrade to latest genai SDK for latest bug fixes (including the above)
- Removed specific 429 handling for uncaught rejections.

Fixes https://b.corp.google.com/issues/413760164
2025-05-07 16:38:06 -07:00
olcan
06274153ba support for mcp tools 2025-05-05 17:10:45 -07:00
Allen Hutchison
b38e28b012 Fix an issue where types/react was a different version from our main … (#231)
Co-authored-by: Brandon Keiji <brandonkeiji@google.com>
2025-04-30 16:33:43 -07:00
Brandon Keiji
15463d1a57 fix: point start.sh to relative path (#209) 2025-04-29 02:44:59 +00:00
Olcan
d1fd9cdf67 enable servers in sandbox to listen on localhost (127.0.0.1) instead of 0.0.0.0, ensuring servers can be container/host-agnostic (#207)
* enable servers in sandbox to listen on localhost (127.0.0.1) instead of 0.0.0.0, ensuring servers can be container/host-agnostic

* Merge remote-tracking branch 'origin/main' into sandbox_localhost_works
2025-04-28 18:40:24 -07:00
Brandon Keiji
66b08209b2 feat: publish docker image alongside npm package (#197) 2025-04-28 13:25:19 -07:00
Taylor Mullen
b22ce6dc49 Upgrade @google/genai to latest.
- Motivation of this upgrade is to enable us to get convenient access to the thinking budget config changes for 2.5 thinking models. This will be key to getting our model to take a bit more time for various requests.
2025-04-27 13:48:34 -07:00
Taylor Mullen
1dcb9b0b3d Cleanup outdated packages in server/cli.
- Found that pre-backend front end split we had a number of packages that we hadn't revisisted. Went through and cleaned them up (i.e. cli needing genai).
2025-04-27 13:41:21 -07:00
Brandon Keiji
92c218fa42 feat: prototype publish sandbox script with npm package (#182) 2025-04-25 17:30:50 -07:00
Brandon Keiji
50d5885d99 feat: add flag to customize package version during pre-release staging (#155) 2025-04-24 13:02:49 -07:00