generate-pr-report

Generates PR/MR descriptions from three-dot git diffs with environment variable detection.

Updated Sep 8, 2026
One-click install
npx skills add https://github.com/lucaszhh/agents --skill generate-pr-report-lucaszhh
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: generate-pr-report
Source: https://github.com/lucaszhh/agents/tree/main/skills/generales/generate-pr-report
Command: npx skills add https://github.com/lucaszhh/agents --skill generate-pr-report-lucaszhh

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? Writing accurate Pull Request or Merge Request descriptions is tedious and error-prone: developers often compare against the wrong base (two-dot diff), miss newly introduced environment variables that break deployments, and produce unstructured reports. This Skill automates the analysis of branch changes against develop and produces a complete, template-compliant report. ## Core Features & Use Cases - Three-dot diff analysis: Compares the feature branch against the merge-base of develop, ensuring only the branch's own changes are reported, and groups changes by architectural layer (domain, data layer, UI, controllers). - Stack-aware env var detection: Scans the diff for new environment variables across Next.js, LoopBack 4, NestJS, Go, and Vite, classifying them as Server/Client/Renamed with criticality levels and generating a blocking alert table via the included Python script. - Direct-to-disk report generation: Writes a structured Markdown report following the official GitLab issue template to .agents/reports/pr_<branch>.md, including reproduction steps, expected results, and detected gaps. - Use Case: Before opening a merge request, ask the agent to generate the PR report; it detects that a new MXM_KEY_TURNER variable was added to LoopBack's keys.ts and flags it as a deploy-blocking requirement at the top of the report. ## Quick Start Ask the agent to generate the PR report for the current branch against develop and save it to disk.

Frequently Asked Questions about generate-pr-report

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate a PR description from a git diff automatically?▼

Run the skill on your feature branch; it computes the merge-base against develop, extracts a three-dot diff, classifies changes by architectural layer, and writes a structured Markdown report to .agents/reports/pr_<branch>.md following the official template.

What is the difference between two-dot and three-dot git diff for PR reports?▼

A three-dot diff (BASE...HEAD) compares HEAD against the merge-base, showing only your branch's own changes. A two-dot diff includes changes merged into develop by other branches, which pollutes the report with work you did not do.

How to detect new environment variables in a pull request?▼

Run the included detect_env_vars.py script, which scans the three-dot diff for process.env, NEXT_PUBLIC_, VITE_, os.Getenv, and config files like docker-compose and keys.ts. It classifies each variable by type, fallback presence, and boot-blocking criticality.

Does the env var detection support Next.js, NestJS, and LoopBack?▼

Yes, the scanner is stack-aware and supports Next.js (envClient/envServer zod schemas), LoopBack 4 (keys.ts with EnvLoader boot validation), NestJS (ConfigService), Go (os.Getenv), and Vite (import.meta.env). It also handles multi-service repos by attributing variables to service subdirectories.

Why does the report flag renamed environment variables as critical?▼

A renamed key (e.g., MXM_KEYCLOAK_FRONTEND_CLIENT_ID to MXM_KEYCLOAK_PUBLIC_CLIENT_ID) requires updating the .env name in every environment. If the old name remains, the service reads undefined and fails at boot when the key is validated by EnvLoader.

When should I not use this PR report generator?▼

Do not use it for QA test checklists (use generate-qa-checklist), CHANGELOG updates (use generate-changelog), or deep technical code reviews (use nextjs-code-review). It is scoped to documenting branch changes for PR/MR descriptions.