Skip to content

Conversation

@marcusquinn
Copy link
Owner

@marcusquinn marcusquinn commented Jan 18, 2026

Summary

  • Add new 🛑 MANDATORY: File Discovery section after the git check section
  • Same prominence as Pre-Edit Git Check with "failure = bug" language
  • Remove duplicate content from Quick Reference section
  • Update Critical Rules to reference new section

Motivation

During a session, mcp_glob was used twice when Bash alternatives (git ls-files, fd) were available. The existing instruction was in Quick Reference but wasn't being followed consistently.

Elevating to MANDATORY section with the same weight as the git check should improve compliance.

Changes

  • .agent/AGENTS.md: +22/-23 lines (net -1 line due to deduplication)

Testing

  • Local linting passed
  • ShellCheck: No violations
  • Secretlint: No secrets detected

Summary by CodeRabbit

  • Documentation
    • Added a new mandatory "File Discovery" section with explicit guidance and decision table for choosing file-discovery commands.
    • Updated the Quick Reference to point to the new mandatory guidance.
    • Removed duplicated/verbose legacy instructions and consolidated file-discovery guidance for clarity and consistency.

✏️ Tip: You can customize this high-level summary in your review settings.

- Add new '🛑 MANDATORY: File Discovery' section after git check
- Same prominence as Pre-Edit Git Check with failure = bug language
- Remove duplicate content from Quick Reference section
- Update Critical Rules to reference new section

This addresses compliance issues where mcp_glob was used despite
Bash alternatives being available. The elevated positioning should
improve adherence to the file discovery guidelines.
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jan 18, 2026

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.

Walkthrough

The PR restructures file-discovery guidance in .agent/AGENTS.md, adding a mandatory "File Discovery" section with explicit rules to avoid mcp_glob when Bash tools are available, updating cross-references (Quick Reference), and removing duplicated procedural/rationale blocks.

Changes

Cohort / File(s) Summary
File Discovery Guidance Reorganization
.agent/AGENTS.md
Added mandatory "MANDATORY: File Discovery" with self-check steps and a decision table (prefer git ls-files, fd, rg, etc. when Bash is available); updated Quick Reference to point to the new section; removed previous duplicated verbose guidance and fallback/rationale text.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Poem

🔎 A tidy rule now leads the way,
Bash tools first — mcp_glob must stay,
Quick Reference points where answers hide,
One clear section, no duplicate guide. ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and specifically describes the main change: elevating an mcp_glob warning from general guidance to a MANDATORY section, which aligns with the refactoring work shown in the summary.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist
Copy link

Summary of Changes

Hello @marcusquinn, 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 refactors the documentation for AI agents by elevating the warning against using mcp_glob to a new, mandatory section. The goal is to enforce the use of more efficient Bash alternatives like git ls-files and fd for file discovery, preventing CPU-intensive operations on large codebases. This change streamlines the guidelines, making critical instructions more prominent and easier to follow for improved agent behavior.

Highlights

  • Elevated mcp_glob warning: The guidance on avoiding mcp_glob in favor of Bash alternatives has been moved to a new, highly visible "🛑 MANDATORY: File Discovery" section.
  • Improved compliance: This change aims to improve compliance with file discovery best practices by giving the warning the same prominence as other critical checks, explicitly stating that failure to comply is a bug.
  • Content Refactoring: Duplicate information regarding mcp_glob usage has been removed from the "Quick Reference" section, and the "Critical Rules" have been updated to reference the new mandatory section.
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.

@augmentcode
Copy link

augmentcode bot commented Jan 18, 2026

🤖 Augment PR Summary

Summary: This PR strengthens agent guidance around file discovery by elevating the existing mcp_glob warning into a new mandatory section.

Changes:

  • Added a new 🛑 MANDATORY: File Discovery section with “failure = bug” language and a clear decision table (`git ls-files` / `fd` / `rg --files` before `mcp_glob`).
  • Removed duplicate “File Discovery” guidance from the Quick Reference section to avoid repetition.
  • Updated Critical Rules to point readers to the new mandatory section for file discovery behavior.

Technical Notes: Emphasizes Bash-based alternatives as the default because they are faster and typically respect ignore rules, reserving mcp_glob for cases where Bash tooling is unavailable.

🤖 Was this summary useful? React with 👍 or 👎

Copy link

@augmentcode augmentcode bot left a comment

Choose a reason for hiding this comment

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

Review completed. No suggestions at this time.

Comment augment review to trigger a new review at any time.

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 effectively refactors the agent guidelines to elevate the warning against using mcp_glob into a new mandatory section. The change is well-motivated, clearly written, and successfully emphasizes the use of more performant alternatives for file discovery. My review includes one suggestion to make the command examples more generic, which should improve their interpretation by AI agents and prevent incorrect tool usage.

.agent/AGENTS.md Outdated
Comment on lines 108 to 110
| Git-tracked files | `git ls-files '*.md'` | Instant, most common case |
| Untracked/system files | `fd -e md` or `fd -g '*.md'` | Fast, respects .gitignore |
| Content + file list | `rg --files -g '*.md'` | Fast, respects .gitignore |

Choose a reason for hiding this comment

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

medium

The command examples in the table are specific to Markdown files ('*.md' and -e md). While this is a good concrete example, it might be beneficial to use more generic placeholders. This will help ensure an AI agent understands the commands apply to any file type and doesn't mistakenly fall back to mcp_glob for non-Markdown files.

Suggested change
| Git-tracked files | `git ls-files '*.md'` | Instant, most common case |
| Untracked/system files | `fd -e md` or `fd -g '*.md'` | Fast, respects .gitignore |
| Content + file list | `rg --files -g '*.md'` | Fast, respects .gitignore |
| Git-tracked files | `git ls-files '<pattern>'` | Instant, most common case |
| Untracked/system files | `fd -e <ext>` or `fd -g '<pattern>'` | Fast, respects .gitignore |
| Content + file list | `rg --files -g '<pattern>'` | Fast, respects .gitignore |

@github-actions
Copy link

🔍 Code Quality Report

�[0;35m[MONITOR]�[0m Code Review Monitoring Report

�[0;34m[INFO]�[0m Latest Quality Status:
SonarCloud: 0 bugs, 0 vulnerabilities, 274 code smells

�[0;34m[INFO]�[0m Recent monitoring activity:
Sun Jan 18 21:04:23 UTC 2026: Code review monitoring started
Sun Jan 18 21:04:23 UTC 2026: SonarCloud - Bugs: 0, Vulnerabilities: 0, Code Smells: 274
Sun Jan 18 21:04:23 UTC 2026: Qlty - 0 issues found, auto-formatting applied
Sun Jan 18 21:04:25 UTC 2026: Codacy analysis completed with auto-fixes

📈 Current Quality Metrics

  • BUGS: 0
  • CODE SMELLS: 274
  • VULNERABILITIES: 0

Generated on: Sun Jan 18 21:05:05 UTC 2026


Generated by AI DevOps Framework Code Review Monitoring

Address review feedback from gemini-code-assist: use <pattern> and <ext>
placeholders instead of specific '*.md' examples to ensure AI agents
understand the commands apply to any file type.
@sonarqubecloud
Copy link

@github-actions
Copy link

🔍 Code Quality Report

�[0;35m[MONITOR]�[0m Code Review Monitoring Report

�[0;34m[INFO]�[0m Latest Quality Status:
SonarCloud: 0 bugs, 0 vulnerabilities, 274 code smells

�[0;34m[INFO]�[0m Recent monitoring activity:
Sun Jan 18 21:08:23 UTC 2026: Code review monitoring started
Sun Jan 18 21:08:24 UTC 2026: SonarCloud - Bugs: 0, Vulnerabilities: 0, Code Smells: 274
Sun Jan 18 21:08:24 UTC 2026: Qlty - 0 issues found, auto-formatting applied
Sun Jan 18 21:08:26 UTC 2026: Codacy analysis completed with auto-fixes

📈 Current Quality Metrics

  • BUGS: 0
  • CODE SMELLS: 274
  • VULNERABILITIES: 0

Generated on: Sun Jan 18 21:09:06 UTC 2026


Generated by AI DevOps Framework Code Review Monitoring

@marcusquinn marcusquinn merged commit dd16c31 into main Jan 18, 2026
9 checks 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.

1 participant