Check agent files in pull requests
When a pull request changes a CLAUDE.md, AGENTS.md or other agent file, the check comments a score and the problems it found.
What it checks
Only the agent files the pull request changes. A pull request that touches none of them is skipped and costs nothing.
- CLAUDE.md and AGENTS.md, at the root or in any folder
- .cursorrules and files under .cursor/rules
- .github/copilot-instructions.md
- GEMINI.md
A later push is checked again only when it changes an agent file. The one comment is updated, so a pull request carries one comment, not a new one per commit.
Commands and paths
The check also names commands in your agent files that run an npm, pnpm, yarn or bun script your package.json does not have, and paths in inline code that are not in the repository. For that, the action sends your root package.json and the package.json of each workspace. These findings do not change the score yet, so fail-below never fails a pull request because of them.
The action sends the names of the files in your repository, not their contents, so the check can tell which paths exist. Nothing is stored.
To turn that off, add send-file-list: false under with. Then only the package.json files are sent, with a yes or no for whether the repository has other package.json files, and the paths check is skipped. None of this costs anything extra.
Free and Pro
5 checks a month. Each check reads all the changed agent files together and shows the score, the tokens they cost every session and the top 3 problems.
Every finding, with the files checked together. Paid from your credits.
Set it up
- Create a key in settings, under GitHub checks.
- Add it to your repository as an Actions secret named FMP_KEY.
- Add this workflow as .github/workflows/agent-check.yml:
name: Agent file check
on:
pull_request:
paths:
- "**/CLAUDE.md"
- "**/AGENTS.md"
- ".cursorrules"
- ".cursor/rules/**"
- ".github/copilot-instructions.md"
- "GEMINI.md"
permissions:
contents: read
pull-requests: write
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: GDM-Digital-Media-Group/fmp-agent-check@v1
with:
fmp-key: ${{ secrets.FMP_KEY }}To fail the check on a low score, add fail-below: 70 under with. If FixMyPrompt cannot be reached, or your free checks are used up, the check passes.
Want to check one file by hand first? Use the CLAUDE.md checker.