feat(tracker): support extension-contributed tracker directory and ensure project precedence#23836
feat(tracker): support extension-contributed tracker directory and ensure project precedence#23836moisgobg wants to merge 1 commit intofeat/builtin-conductorfrom
Conversation
…sure project precedence - Add 'tracker' property to ExtensionConfig to allow extensions to specify task tracking directories. - Fix extension loading to pass tracker configuration from extensions. - Implement project-level precedence for tracker directory over extension defaults. - Add comprehensive tests for tracker directory resolution and precedence.
|
Hi @moisgobg, thank you so much for your contribution to Gemini CLI! We really appreciate the time and effort you've put into this. We're making some updates to our contribution process to improve how we track and review changes. Please take a moment to review our recent discussion post: Improving Our Contribution Process & Introducing New Guidelines. Key Update: Starting January 26, 2026, the Gemini CLI project will require all pull requests to be associated with an existing issue. Any pull requests not linked to an issue by that date will be automatically closed. Thank you for your understanding and for being a part of our community! |
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a significant enhancement to the configuration system, allowing extensions to specify their preferred task tracking directories. Crucially, it establishes a clear precedence rule where any user-defined project-level tracker directory will always override an extension's default, ensuring user control. This foundational change paves the way for future integrations, such as the Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request introduces configurable task tracker directories for the CLI. It adds new settings for both user and extension-defined tracker directories, with user settings taking precedence. The Storage class now includes logic to resolve and validate these custom directories, ensuring they remain within the project root for security. The Config class and TrackerService have been updated to utilize this new directory resolution. Comprehensive unit and integration tests have been added to cover various path scenarios and the interaction between user and extension settings. I have no feedback to provide on the review comments, as none were supplied.
Note: Security Review did not run due to the size of the PR.
Summary
This PR enables extensions to contribute their own task tracking directory via their
gemini-extension.jsonconfiguration, while ensuring that user-defined project-level settings always take absolute precedence.This core capability is a prerequisite for the upcoming
sddextension integration, allowing it to default its tracker directory to.gemini/trackerautomatically.Details
trackerproperty toExtensionConfig: Properly types the configuration so extensions can declare their task tracking directory._buildExtensionin theExtensionManagerto actually parse and pass thetrackerconfiguration object from the extension up to the CLI.settings.general.tracker.directorycorrectly overrides theextensionTrackerSettingsdefault, and added comprehensive test coverage for these precedence rules inconfig.test.ts.Related Issues
Fixes #23724
How to Validate
npm run build:all.sdd) to use a custom tracker directory (e.g.,.gemini/tracker) and verify that tasks are created there..gemini/settings.jsonwith a different custom directory for the tracker.npm test -w @google/gemini-cli -- src/config/config.test.ts.Pre-Merge Checklist