Skip to content

merge duplicate imports packages/cli/src subtask2#22051

Merged
scidomino merged 21 commits intogoogle-gemini:mainfrom
Nixxx19:nityam/merge-duplicate-imports-subtask2-fixed
Mar 11, 2026
Merged

merge duplicate imports packages/cli/src subtask2#22051
scidomino merged 21 commits intogoogle-gemini:mainfrom
Nixxx19:nityam/merge-duplicate-imports-subtask2-fixed

Conversation

@Nixxx19
Copy link
Copy Markdown
Contributor

@Nixxx19 Nixxx19 commented Mar 11, 2026

Fixes #19753

@Nixxx19 Nixxx19 requested a review from a team as a code owner March 11, 2026 17:58
@Nixxx19
Copy link
Copy Markdown
Contributor Author

Nixxx19 commented Mar 11, 2026

@scidomino ready for review, thanks!!

@gemini-code-assist
Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, 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 addresses the issue of duplicate import statements across multiple files in the packages/cli/src/ui/components directory. The primary goal is to enhance code clarity and maintainability by consolidating these redundant imports into single, more organized statements. This refactoring effort contributes to a cleaner and more consistent codebase.

Highlights

  • Duplicate Imports: This PR merges duplicate import statements in several files, improving code readability and maintainability.
  • Code Consistency: The changes ensure a consistent style of importing modules and types throughout the codebase.
  • Dependency Management: By removing redundant imports, the PR helps to avoid potential conflicts and confusion related to dependencies.
Changelog
  • packages/cli/src/ui/IdeIntegrationNudge.tsx
    • Consolidated RadioButtonSelect and RadioSelectItem imports into a single import statement.
  • packages/cli/src/ui/components/AgentConfigDialog.tsx
    • Consolidated SettingScope, LoadableSettingScope, and LoadedSettings imports into a single import statement.
  • packages/cli/src/ui/components/AskUserDialog.tsx
    • Consolidated checkExhaustive and Question imports into a single import statement.
  • packages/cli/src/ui/components/Checklist.tsx
    • Reordered import statements, moving useMemo above theme.
  • packages/cli/src/ui/components/DetailedMessagesDisplay.tsx
    • Reordered import statements, moving React type import above useRef and useCallback.
  • packages/cli/src/ui/components/EditorSettingsDialog.test.tsx
    • Consolidated SettingScope and LoadedSettings imports into a single import statement.
  • packages/cli/src/ui/components/FolderTrustDialog.tsx
    • Consolidated RadioButtonSelect and RadioSelectItem imports into a single import statement.
  • packages/cli/src/ui/components/GradientRegression.test.tsx
    • Consolidated SessionStatsState import.
  • packages/cli/src/ui/components/Help.test.tsx
    • Consolidated CommandKind and SlashCommand imports into a single import statement.
  • packages/cli/src/ui/components/HistoryItemDisplay.test.tsx
    • Consolidated MessageType and HistoryItem imports into a single import statement.
  • packages/cli/src/ui/components/InputPrompt.test.tsx
    • Consolidated several imports for better organization.
  • packages/cli/src/ui/components/InputPrompt.tsx
    • Reordered and consolidated imports for better organization and readability.
  • packages/cli/src/ui/components/LogoutConfirmationDialog.tsx
    • Consolidated RadioButtonSelect and RadioSelectItem imports into a single import statement.
  • packages/cli/src/ui/components/LoopDetectionConfirmation.tsx
    • Consolidated RadioButtonSelect and RadioSelectItem imports into a single import statement.
  • packages/cli/src/ui/components/ModelStatsDisplay.test.tsx
    • Consolidated LoadedSettings and SessionMetrics imports into a single import statement.
  • packages/cli/src/ui/components/MultiFolderTrustDialog.tsx
    • Consolidated RadioButtonSelect and RadioSelectItem imports into a single import statement.
  • packages/cli/src/ui/components/PermissionsModifyTrustDialog.test.tsx
    • Consolidated imports from vitest.
  • packages/cli/src/ui/components/PolicyUpdateDialog.tsx
    • Consolidated imports from '@google/gemini-cli-core' and RadioButtonSelect related imports.
  • packages/cli/src/ui/components/RewindConfirmation.tsx
    • Consolidated RadioButtonSelect and RadioSelectItem imports into a single import statement.
  • packages/cli/src/ui/components/SessionBrowser.test.tsx
    • Consolidated SessionBrowser and SessionBrowserProps imports into a single import statement.
  • packages/cli/src/ui/components/SessionBrowser.tsx
    • Reordered import statements for better readability.
  • packages/cli/src/ui/components/SessionSummaryDisplay.test.tsx
    • Consolidated SessionMetrics import.
  • packages/cli/src/ui/components/SettingsDialog.tsx
    • Consolidated SettingScope, LoadableSettingScope, and Settings imports into a single import statement.
  • packages/cli/src/ui/components/ShellInputPrompt.tsx
    • Reordered import statements.
  • packages/cli/src/ui/components/StatsDisplay.test.tsx
    • Consolidated SessionMetrics import.
  • packages/cli/src/ui/components/StatsDisplay.tsx
    • Consolidated useSessionStats and ModelMetrics imports into a single import statement.
  • packages/cli/src/ui/components/ToolStatsDisplay.test.tsx
    • Consolidated SessionMetrics import.
  • packages/cli/src/ui/components/messages/CompressionMessage.test.tsx
    • Consolidated CompressionMessage and CompressionDisplayProps imports into a single import statement.
  • packages/cli/src/ui/components/messages/Todo.test.tsx
    • Consolidated CoreToolCallStatus and Todo imports into a single import statement.
  • packages/cli/src/ui/components/messages/Todo.tsx
    • Reordered import statements.
  • packages/cli/src/ui/components/messages/ToolConfirmationMessage.tsx
    • Consolidated RadioButtonSelect and RadioSelectItem imports into a single import statement.
  • packages/cli/src/ui/components/messages/ToolMessageRawMarkdown.test.tsx
    • Consolidated ToolMessage and ToolMessageProps imports into a single import statement.
  • packages/cli/src/ui/components/shared/BaseSelectionList.tsx
    • Consolidated useSelectionList and SelectionListItem imports into a single import statement.
  • packages/cli/src/ui/components/shared/EnumSelector.tsx
    • Reordered import statements.
  • packages/cli/src/ui/components/shared/RadioButtonSelect.test.tsx
    • Reordered import statements and consolidated Box and Text imports from ink.
  • packages/cli/src/ui/components/shared/TextInput.tsx
    • Consolidated useKeypress and Key imports and expandPastePlaceholders and TextBuffer imports.
  • packages/cli/src/ui/components/triage/TriageDuplicates.tsx
    • Consolidated debugLogger, spawnAsync, LlmRole, and Config imports into a single import statement.
  • packages/cli/src/ui/components/triage/TriageIssues.tsx
    • Consolidated debugLogger, spawnAsync, LlmRole, and Config imports into a single import statement.
  • packages/cli/src/ui/components/views/ExtensionRegistryView.tsx
    • Removed an extra newline.
  • packages/cli/src/ui/components/views/McpStatus.tsx
    • Consolidated MCPServerStatus and MCPServerConfig imports into a single import statement.
Activity
Using Gemini Code Assist

The 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 /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

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 .gemini/ folder in the base of the repository. Detailed instructions can be found here.

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.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@gemini-cli gemini-cli bot added priority/p2 Important but can be addressed in a future release. area/core Issues related to User Interface, OS Support, Core Functionality area/platform Issues related to Build infra, Release mgmt, Testing, Eval infra, Capacity, Quota mgmt help wanted We will accept PRs from all issues marked as "help wanted". Thanks for your support! labels Mar 11, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request focuses on refactoring by merging duplicate imports across numerous files in packages/cli/src. The changes are purely stylistic and improve code consistency and readability. All modifications are appropriate and have been applied correctly. I have no further comments.

@scidomino scidomino enabled auto-merge March 11, 2026 19:38
auto-merge was automatically disabled March 11, 2026 19:51

Head branch was pushed to by a user without write access

@Nixxx19
Copy link
Copy Markdown
Contributor Author

Nixxx19 commented Mar 11, 2026

@scidomino could you please allow workflows again, thanks!

@Nixxx19
Copy link
Copy Markdown
Contributor Author

Nixxx19 commented Mar 11, 2026

thanks!

Merged via the queue into google-gemini:main with commit be16cae Mar 11, 2026
27 checks passed
liamhelmer pushed a commit to badal-io/gemini-cli that referenced this pull request Mar 12, 2026
SUNDRAM07 pushed a commit to SUNDRAM07/gemini-cli that referenced this pull request Mar 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/core Issues related to User Interface, OS Support, Core Functionality area/platform Issues related to Build infra, Release mgmt, Testing, Eval infra, Capacity, Quota mgmt help wanted We will accept PRs from all issues marked as "help wanted". Thanks for your support! priority/p2 Important but can be addressed in a future release.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cleanup existing import/no-duplicates warnings and suppressions

2 participants