
Greptile
PluginGreptile 官方 AI 代码评审插件:查看并处理 GitHub / GitLab PR 的评审意见,提 PR 前评审当前分支,检索团队知识库与编码规范。需 Greptile 账号(OAuth 登录,有免费档),本机需有 Node。
Greptile
Greptile is an AI code review agent for GitHub and GitLab that automatically reviews pull requests. This plugin gives Claude Code two ways to work with it:
- the Greptile MCP server, for reading and resolving review results, and for searching your organization's knowledge base and coding patterns
- the Greptile CLI, for dispatching a review of your working branch before a pull request exists
They are two ends of one pipeline. The CLI dispatches reviews; the MCP server reads them back — both the ones the CLI dispatched (source: "headless") and the ones Greptile ran on your pull requests (source: "pr").
Setup
Nothing to install and no API key to create.
MCP server. Open the /mcp menu and authenticate greptile. Your browser opens auth.greptile.com; sign in and approve access. Claude Code stores and refreshes the tokens.
CLI. Run /greptile:login once and sign in through the same OAuth provider. The CLI ships with this plugin, so there is no npm or Homebrew install to do — but it is a Node program, so Node must be on your machine.
The two sign-ins are separate: same Greptile account, same OAuth provider, but the CLI keeps its own credentials in ~/.greptile/auth.json while Claude Code keeps the MCP tokens in its own store. Use whichever surface you need; you only have to sign in to that one.
Commands
/greptile:review- Review the current branch against its base. Accepts a base branch and free-text instructions ("focus on the auth changes")./greptile:login- Sign the CLI in to your Greptile account.
Tools
Account and repositories
get_me- Show your authenticated identity and organization membershipslist_repositories- List repositories accessible to your account
Pull requests
list_merge_requests/list_pull_requests- List PRs, filtered by repository, branch, author, or stateget_merge_request- Detailed PR info, including which review comments have been addressed by later commitslist_merge_request_comments- All comments on a PR, with Greptile, human, and other bot comments distinguished bysourceType
Code reviews
list_code_reviews- List code reviews, filtered by repository or statusget_code_review- Full review body, status, summary citations, and review metadatatrigger_code_review- Start a Greptile review on a pull request (GitHub and GitLab)search_greptile_comments- Search Greptile's review comments across every review, on pull requests and on headless CLI runs alike
Knowledge base
list_knowledge_bases- Repositories your organization has knowledge base data forlist_knowledge_base_documents- Document paths in a repository's published knowledge baseget_knowledge_base_document- Markdown body of a single knowledge base documentsearch_knowledge_base- Substring search across one repository's knowledge base
Custom context
list_custom_context- Your organization's coding patterns and rulesget_custom_context- Details for one entry, including evidence and linked commentssearch_custom_context- Search entries by contentcreate_custom_context- Create a new entry, either a custom instruction (the default) or a pattern
Analytics
get_analytics_overview- Summary metrics and period changes, chart series, and repository, contributor, and pull request rankingslist_analytics_findings- Findings with severity and security totals and trends, filterable by team, repository, author, severity, or statuslist_analytics_filter_options- The teams, repositories, and authors available to you as analytics filters
Example usage
- "Review my current branch with Greptile and fix what it finds"
- "Show me Greptile's comments on my current PR and help me resolve them"
- "What issues did Greptile find on PR #123?"
- "Search our knowledge base for how authentication works in this repo"
Bundled CLI
scripts/greptile.mjs is the Greptile CLI, vendored from the published npm package
greptile (its dist/greptile.js, renamed only so Node reads it as ESM without a
sibling package.json). scripts/greptile.version records which release it is, and
CI verifies the file byte-for-byte against that version's npm tarball, so the copy
running here is the same one npm serves.
Because the CLI ships with the plugin, it updates with the plugin — not through
greptile update, npm, or brew. Any separate greptile you have installed is
untouched and unused by these commands, though both share your login at
~/.greptile/auth.json.
Network access
This plugin registers no hooks. What it contacts:
api.greptile.com— the MCP server, the CLI's API, and CLI telemetry (below).auth.greptile.com— OAuth sign-in, for both surfaces.app.greptile.com— link targets printed in review output.127.0.0.1— a loopback listener the CLI opens to receive the OAuth callback during/greptile:login, closed as soon as the redirect arrives.
Telemetry
The bundled CLI reports anonymous usage events to /v1/telemetry on the same
host as its API. The events are lifecycle signals — cli_first_run,
cli_login_started, cli_login_failed, cli_onboarding_started,
cli_skill_installed, cli_skill_updated, cli_review_blocked,
cli_update_completed — carrying your install method, OS, architecture,
whether the run was interactive, and which agent surface it ran under. Nothing
else: no code, no repository or branch names, no file paths, no review content.
Event-specific fields are fixed values: method, exit_code, reason, the
version strings on an update, and the name of the Greptile-authored skill on
the two skill events.
Inside Claude Code the CLI is always non-interactive, so it cannot ask you to
decide and does not try. It falls back to anonymous mode: a random
cli:<uuid> stored in telemetry.json, no account token attached, and no
profile built on the other end. If you have separately opted in from a
standalone greptile on the same machine, that decision carries over here and
events are sent under your account instead.
To turn it off, any one of these is enough:
export GREPTILE_TELEMETRY_DISABLED=1 # or DO_NOT_TRACK=1
greptile settings set telemetry false
CI=1 also disables it, and a CLI pointed at a self-hosted Greptile sends no
telemetry at all.
Downloads
One thing here fetches software, and this is it. When a review summary
contains a Mermaid diagram, the CLI renders it with
mmdr, a small standalone binary fetched on first use from
github.com/1jehuang/mermaid-rs-renderer
into ~/.cache/greptile/bin/. The archive is checked against a SHA-256 pinned
per platform inside the bundle and is deleted rather than run if the hash does
not match; the download announces itself on stderr, and failing to get it
degrades the diagram to a link instead of failing the review. Setting
GREPTILE_NO_AUTO_INSTALL=1 skips it. /greptile:review already sets that
variable, so the plugin does not download it — the code path is reachable
only if you invoke the bundled CLI yourself without it.
Documentation
相關資源

GitHub
Plugin接入 GitHub 官方远程 MCP 服务器,在 Claude Code 里管理 Issue 与 PR、评审代码、搜索仓库并调用 GitHub API;需要配置 GITHUB_PERSONAL_ACCESS_TOKEN。
anthropics/claude-plugins-official40.3k
GitHub CLI
CLIGitHub 官方命令行:在终端里管理 PR、Issue、Release 与 Actions 工作流,多数命令支持 --json 输出便于 agent 解析,并提供官方 agent skill。需先 gh auth login 登录。
cli/cli46.7k
GitHub MCP Server
MCPGitHub 官方 MCP 服务器:让 agent 读写仓库与代码,管理 Issue 和 PR,查看 Actions 工作流与代码扫描告警。可接托管远程服务或用 Docker 本地运行,需个人访问令牌或 OAuth 授权。
github/github-mcp-server33.7k
GitLab
Plugin接入 GitLab 官方远程 MCP 服务(Beta),让 Claude 操作仓库、合并请求、CI/CD 流水线、议题与 Wiki;连接 GitLab.com,需在顶级群组开启 MCP 访问并经浏览器 OAuth 授权。收录于 Anthropic 官方插件市场。
anthropics/claude-plugins-official40.4k
Commit Commands
PluginGit 提交命令集:/commit 按仓库风格生成提交信息,/commit-push-pr 一步完成建分支、提交、推送与创建 PR(需要 gh CLI),/clean_gone 清理远端已删除的本地分支。Anthropic 官方插件。
anthropics/claude-code151k
Code Review
Plugin用多个并行子代理评审 PR,逐条按置信度打分、过滤误报,可把结果发成 PR 评论。Anthropic 官方插件,需要已登录的 GitHub CLI。
anthropics/claude-code151k