Skip to content

Conversation

@kooksee
Copy link
Contributor

@kooksee kooksee commented Jan 21, 2026

No description provided.

@gemini-code-assist
Copy link

Summary of Changes

Hello @kooksee, 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 enhances the protobuild command-line tool by improving its robustness and user experience. Key changes include better handling of interactive terminal input, a more reliable method for constructing protoc commands with unique include paths, and a critical fix for file resource management to prevent leaks. These updates contribute to a more stable and predictable tool behavior.

Highlights

  • Terminal Input Handling: Introduced a check to detect if the command is being run interactively without piped input, guiding users to the help message in such scenarios. This prevents the command from hanging or misbehaving when stdin is a terminal.
  • Dependency Update: Added the golang.org/x/term package to facilitate terminal interaction detection, specifically for checking stdin.
  • Protoc Include Path Refinement: Improved the logic for constructing protoc commands by ensuring that include paths from vendor directories, the current working directory, and configured includes are all unique and correctly applied.
  • Resource Management Fix: Corrected the placement of defer statements in the copyFile function to ensure that file handles are closed only after they have been successfully opened, preventing potential resource leaks or panics.
  • Code Clean-up: Removed an unused log/slog import and associated logging calls from the shutil package, streamlining the codebase.

🧠 New Feature in Public Preview: You can now enable Memory to help Gemini Code Assist learn from your team's feedback. This makes future code reviews more consistent and personalized to your project's style. Click here to enable Memory in your admin console.

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.

Copy link

@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 introduces several updates, including adding the golang.org/x/term dependency to improve command-line usability by showing help when run interactively. It also includes refactorings, such as renaming variables for clarity and optimizing how command strings are built. I've found a critical issue regarding a file handle leak and a medium-severity issue related to string construction. Please see the detailed comments below for suggestions.

@kooksee kooksee merged commit a8e3fba into main Jan 21, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants