load-mr-context

$npx mdskill add TheBushidoCollective/han/load-mr-context

Fetch complete merge request details instantly from GitLab.

  • Retrieves MR metadata, diffs, pipelines, and reviews for any branch.
  • Depends on GitLab MCP tools for structured data access.
  • Executes silent lookups to locate open MRs and gather context.
  • Outputs concise summaries of status, changes, and blockers.

SKILL.md

.github/skills/load-mr-contextView on GitHub ↗
---
name: load-mr-context
description: Load MR context for the current branch using GitLab MCP tools
---

# Load MR Context

## Name

gitlab:load-mr-context - Load merge request context for the current branch

## Synopsis

```
/load-mr-context [project-path] [branch]
```

## Description

Loads the full context of an open merge request for the given branch, including description, changes, pipeline status, and review comments. Uses GitLab MCP tools for structured data access.

## Implementation

Given `project-path` and `branch` arguments:

1. Use `mcp__plugin_gitlab_gitlab__list_merge_requests` with `project_id: "PROJECT_PATH"`, `source_branch: "BRANCH"`, `state: "opened"` to find the MR
2. If no MR is found, report that no open MR exists for this branch and stop
3. If an MR exists, gather context **silently** (do not narrate each step):
   - Use `mcp__plugin_gitlab_gitlab__get_merge_request` with the MR IID to read description, labels, reviewers, and metadata
   - Use `mcp__plugin_gitlab_gitlab__get_merge_request_diffs` to understand what has changed
   - Check pipeline status for the branch
   - Check for review notes/discussions
   - Check for linked issues mentioned in the MR description
4. Present a concise summary:
   - MR title, number, and status
   - Key points from the description
   - Files changed (count and notable files)
   - Pipeline status (passing/failing)
   - Review status (approved, changes requested, pending)
   - Any blocking issues or failing pipelines

## Example Interaction

```
User: /load-mr-context my-group/my-project feat/mr-context

Claude: ## MR !42: Add MR context detection hooks

- **Status**: Open, 1 review pending
- **Description**: Adds SessionStart hooks to GitLab plugin that detect open MRs on the current branch
- **Changes**: 4 files (+120, -8)
- **Pipeline**: All stages passing
- **Reviews**: 1 approved, 1 pending from @reviewer

Ready to assist with this MR.
```

## Arguments

- `project-path` (required): GitLab project path (e.g., `group/project` or numeric ID)
- `branch` (required): Branch name to find the MR for

## Tips

- This skill is typically invoked automatically when starting a session on a feature branch
- All data is fetched via MCP tools (no CLI commands needed)
- The summary is kept concise to avoid cluttering the session start

More from TheBushidoCollective/han

SkillDescription
absinthe-resolversUse when implementing GraphQL resolvers with Absinthe. Covers resolver patterns, dataloader integration, batching, and error handling.
absinthe-schemaUse when designing GraphQL schemas with Absinthe. Covers type definitions, interfaces, unions, enums, and schema organization patterns.
absinthe-subscriptionsUse when implementing real-time GraphQL subscriptions with Absinthe. Covers Phoenix channels, PubSub, and subscription patterns.
act-docker-setupUse when configuring Docker environments for act, selecting runner images, managing container resources, or troubleshooting Docker-related issues with local GitHub Actions testing.
act-local-testingUse when testing GitHub Actions workflows locally with act. Covers act CLI usage, Docker configuration, debugging workflows, and troubleshooting common issues when running workflows on your local machine.
act-workflow-syntaxUse when creating or modifying GitHub Actions workflow files. Provides guidance on workflow syntax, triggers, jobs, steps, and expressions for creating valid GitHub Actions workflows that can be tested locally with act.
ameba-configurationUse when configuring Ameba rules and settings for Crystal projects including .ameba.yml setup, rule management, severity levels, and code quality enforcement.
ameba-custom-rulesUse when creating custom Ameba rules for Crystal code analysis including rule development, AST traversal, issue reporting, and rule testing.
ameba-integrationUse when integrating Ameba into development workflows including CI/CD pipelines, pre-commit hooks, GitHub Actions, and automated code review processes.
analyze-performanceAnalyze performance metrics and identify slow transactions in Sentry