chore: add a gemini cli hook to run format on file changes#242
chore: add a gemini cli hook to run format on file changes#242MichaelDoyle wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces a new Dart CLI hook to run 'dart format' on specific files or the entire project. The review feedback suggests correcting a typo in the documentation, simplifying the JSON parsing logic using Dart's pattern matching to reduce nesting, and improving the robustness of stdout/stderr handling by checking types directly and adhering to single-line if statement conventions.
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces a new Dart script, tools/hooks/format.dart, which serves as a Gemini CLI hook to automate code formatting via dart format. The script reads a file path from stdin or defaults to the current directory. Feedback was provided regarding the silent suppression of errors during input parsing, which could lead to unintended full-project formatting; it is recommended to log these errors to provide better visibility to the user.
|
WDYT @pavelgj BTW, on a totally separate, but related not, I see we have |
No description provided.