Angular PR Review MCP
Angular PR Review MCP
Переиспользуемый MCP-сервер для автоматизированных рабочих процессов ревью pull request в нескольких Angular-репозиториях.
Этот пакет предоставляет три MCP-инструмента:
get_pr_review_templategenerate_pr_diffread_pr_diffsave_pr_review
Он работает в контексте целевого репозитория (текущей рабочей директории), поэтому один опубликованный пакет можно переиспользовать в любом Angular-приложении.
Требования
Node.js 20+
Установленный Git, доступный в PATH
VS Code с поддержкой Copilot Chat MCP
Related MCP server: @droplinkperformance/bitbucket-mcp-server
Локальная разработка
npm install
npm run build
npm run devПубликация в npm
Если публикуете в открытый доступ:
npm login
npm publish --access publicЕсли публикуете под scoped-пакетом (рекомендуется для аккаунтов/организаций):
Измените поле
nameв package.json на ваш scope, например@your-scope/angular-pr-review-mcp.Опубликуйте:
npm login
npm publish --access publicСоздание отдельного GitHub-репозитория
Из этой папки создайте в вашем аккаунте отдельный репозиторий и запушьте в него:
git init
git branch -M main
git remote add origin https://github.com/<your-username>/angular-pr-review-mcp.git
git add .
git commit -m "Initial reusable Angular PR review MCP package"
git push -u origin mainИспользование из любого Angular-репозитория
Добавьте или обновите .vscode/mcp.json в каждом Angular-репозитории:
{
"servers": {
"angular-pr-review": {
"type": "stdio",
"command": "npx",
"args": ["-y", "angular-pr-review-mcp"],
"cwd": "${workspaceFolder}",
"env": {
"PR_REVIEW_BASE_BRANCH": "main",
"PR_REVIEW_OUTPUT_DIR": "pr_review"
}
}
}
}Для scoped-пакета замените angular-pr-review-mcp на ваше опубликованное имя.
Переменные окружения
PR_REVIEW_BASE_BRANCH: целевая базовая ветка для сравнения (по умолчаниюmain)PR_REVIEW_OUTPUT_DIR: каталог артефактов ревью (по умолчаниюpr_reviewв корне репозитория)PR_REVIEW_REPO_ROOT: переопределение корня репозитория (по умолчанию текущая рабочая директория)PR_REVIEW_SERVER_NAME: имя MCP-сервера (по умолчаниюangular-pr-review)
Рабочий процесс инструментов
generate_pr_diffс SHA коммита.read_pr_diffдля получения содержимого diff.save_pr_reviewдля сохранения markdown-комментариев ревью.
Рекомендуемый порядок:
Сначала
get_pr_review_template, чтобы загрузить локальные критерии ревью и избежать повторного вывода правил при каждом запуске.generate_pr_diffиread_pr_diffдля сбора доказательств.save_pr_reviewдля итогового отчёта.
Сгенерированные файлы записываются в настроенную выходную папку в каждом репозитории, использующем пакет.
Локальный артефакт шаблона
Репозиторий включает pr_review_prompt_template.md, чтобы команды могли версионировать рекомендации по ревью в системе контроля версий.
Инструмент get_pr_review_template возвращает тот же текст политики (с опциональной заменой токена коммита), что помогает делать ревью детерминированными и снижает расход токенов.
Available Tools
4 toolsgenerate_pr_diffB
Generate a PR review diff for a validated Git commit hash and return the resulting diff file path.
Inputs: commitHash (required).
get_pr_review_templateB
Return the local Angular PR review template used to keep review rules consistent and token-efficient.
Inputs: commitHash.
read_pr_diffA
Read the most recently generated PR diff file, or a specific diff by commit hash/file path.
Inputs: filePath, commitHash.
save_pr_reviewB
Save a completed review as a markdown report inside the configured output folder.
Inputs: content (required), commitHash (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 4 tools
Each tool serves a distinct purpose: fetching the review template, generating a diff, reading a diff, and saving a review. There is no overlap or ambiguity in their functionalities.
All tools follow a consistent verb_noun pattern (get, generate, read, save) with clear object references. The only minor deviation is that 'get_pr_review_template' and 'generate_pr_diff' could be seen as slightly more specific verbs, but they are still consistent with the overall style.
With 4 tools, the server is well-scoped for a focused PR review workflow. Each tool covers an essential step: template retrieval, diff generation, diff reading, and saving results, without unnecessary extras.
The tool surface covers the core workflow of generating and reviewing a PR diff. However, a minor gap might be the lack of a tool to fetch PR metadata or commit details beyond the diff, but the current set is sufficient for the stated purpose.
Maintenance
Related MCP Connectors
Read pull requests, builds and work items, and create work items or PR comments in Azure DevOps.
Detect breaking changes, generate changelogs, diff, and validate OpenAPI specs.
Generate changelogs, release emails, help-center articles, banners, and social posts from commits.
Read repositories, pull requests, issues and CI runs; create issues and comments in GitHub.
Related MCP Servers
AlicenseNot gradedqualityDmaintenanceEnables AI-powered code review of Git diffs through natural language, supporting multiple AI models and Git workflows.36Apache 2.0- AlicenseNot gradedqualityBmaintenanceEnables AI-powered pull request review and analysis for Bitbucket Cloud, plus tools to list, create, diff, comment on, and analyze PRs. Supports stdio or HTTP transports with OAuth/bearer auth and pluggable LLM providers.57 npmMIT
- AlicenseNot gradedqualityBmaintenanceEnables deterministic behavioral regression review of pull-request diffs by checking changed code against approved incident-derived contracts. It exposes read-only tools to assess diffs and pull requests, list and fetch contracts, and report outcomes over stdio without mutating repositories.MIT
- AlicenseNot gradedqualityCmaintenanceEnables AI assistants to review GitHub pull requests and GitLab merge requests by fetching PR/MR details and diffs, with optional file-type filtering, and posting inline, general, or batched review comments. Supports self-hosted GitLab and custom project-specific review rules through stdio, SSE, or WebSocket transports.MIT