Skip to main content
Glama

Angular PR Review MCP

Servidor MCP reutilizable para flujos de trabajo automatizados de revisión de pull requests en múltiples repositorios de Angular.

Este paquete expone tres herramientas MCP:

  • get_pr_review_template

  • generate_pr_diff

  • read_pr_diff

  • save_pr_review

Se ejecuta en el contexto del repositorio de destino (el directorio de trabajo actual), por lo que un mismo paquete publicado puede reutilizarse en cualquier aplicación Angular.

Requisitos

  • Node.js 20+

  • Git instalado y disponible en PATH

  • VS Code con soporte para Copilot Chat MCP

Related MCP server: @droplinkperformance/bitbucket-mcp-server

Desarrollo local

npm install
npm run build
npm run dev

Publicar en npm

Si se publica públicamente:

npm login
npm publish --access public

Si se publica como paquete con ámbito (recomendado para propiedad de cuenta/organización):

  1. Cambia el campo name en package.json a tu ámbito, por ejemplo @your-scope/angular-pr-review-mcp.

  2. Publica:

npm login
npm publish --access public

Crear un repositorio de GitHub separado

Desde esta carpeta, crea y sube a un repositorio dedicado en tu cuenta:

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

Usar desde cualquier repositorio de Angular

Añade o actualiza .vscode/mcp.json en cada repositorio de 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"
      }
    }
  }
}

Para un paquete con ámbito, sustituye angular-pr-review-mcp por tu nombre publicado.

Variables de entorno

  • PR_REVIEW_BASE_BRANCH: rama base de destino para la comparación (por defecto main)

  • PR_REVIEW_OUTPUT_DIR: directorio de artefactos de revisión (por defecto pr_review en la raíz del repositorio)

  • PR_REVIEW_REPO_ROOT: anula la raíz del repositorio (por defecto el directorio de trabajo actual)

  • PR_REVIEW_SERVER_NAME: nombre del servidor MCP (por defecto angular-pr-review)

Flujo de trabajo de las herramientas

  1. generate_pr_diff con el SHA del commit.

  2. read_pr_diff para recuperar el contenido del diff.

  3. save_pr_review para guardar los comentarios de revisión en Markdown.

Flujo recomendado:

  1. get_pr_review_template primero, para cargar la rúbrica de revisión local y evitar volver a derivar las reglas en cada ejecución.

  2. generate_pr_diff y read_pr_diff para la recopilación de evidencia.

  3. save_pr_review para el informe final.

Los archivos generados se escriben en la carpeta de salida configurada en cada repositorio consumidor.

Artefacto de plantilla local

El repositorio incluye pr_review_prompt_template.md para que los equipos puedan versionar las guías de revisión en el control de código fuente. La herramienta get_pr_review_template devuelve el mismo texto de política (con sustitución opcional de token de commit), lo que ayuda a mantener las revisiones deterministas y reduce el consumo de tokens.

Available Tools

4 tools
generate_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

    A3.7/5.0

    Scored across 4 tools

    Disambiguation5/5

    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.

    Naming Consistency4/5

    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.

    Tool Count5/5

    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.

    Completeness4/5

    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

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      B
      maintenance
      Enables 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
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables 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