Skip to content
Agentmart
Submit a tool

rhdh-pr-mr

Pushes a topic branch and opens a GitHub pull request or GitLab CEE merge request for CI and agent automation, then links Jira via /rhdh-jira-link only when…

Skill by redhat-developer

IndexedApache-2.0★ 18
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/redhat-developer-rhdh-pr-mr

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Pushes a topic branch and opens a GitHub pull request or GitLab CEE merge request for CI and agent automation, then links Jira via /rhdh-jira-link only when an issue key is known. Use for "open a PR", "create the merge request", "push and open PR/MR after a yarn or base-image bump", or when another CI skill needs a shared opener. Not for plugin changeset publish (/rhdh-pr-create) and not a replacement for midstream createPR.sh inside updateBaseImages.sh.

Use cases: devops, agent-building

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md and code. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found
Runs as
Shell scripts

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/rhdh-pr-mr

What's inside

Skill name
rhdh-pr-mr
Description
Pushes a topic branch and opens a GitHub pull request or GitLab CEE merge request for CI and agent automation, then links Jira via /rhdh-jira-link only when an issue key is known. Use for "open a PR", "create the merge request", "push and open PR/MR after a yarn or base-image bump", or when another CI skill needs a shared opener. Not for plugin changeset publish (/rhdh-pr-create) and not a replacement for midstream createPR.sh inside updateBaseImages.sh.
License
Apache-2.0
Compatibility
bash, git, jq, curl; gh for GitHub; PRIVATE_TOKEN (and optional glab) for GitLab CEE; JIRA_API_TOKEN when linking.
Instructions
69 lines in SKILL.md · view on GitHub

Before installing

  • Ships executable scripts

Files (4)

  • SKILL.md
  • openai.yaml · agents/
  • create-pr-mr.sh · scripts/
  • smoke.sh · tests/

SKILL.md (first lines)

# RHDH PR / MR opener

Shared script for push + open. Caller owns the commit and `/mutation-gate`
approval when an agent is driving. Weekly bots may call the script unattended.

## Boundaries

- **Not** `/rhdh-pr-create` (plugin changesets, recordings, monorepo publish).
- **Does** call `/rhdh-jira-link` `link-pr-mr.js` when `--issue` or `JIRA_ISSUE` is set.
- **Skips** Jira when no key is known — never invent one.
- Midstream `createPR.sh` (distgit) stays for `updateBaseImages.sh` until a later migration.

## Script

```bash
SKILL=<this skill's directory>
"$SKILL/scripts/create-pr-mr.sh" \
  --cwd /path/to/checkout \
  --base main \
  --head chore/my-topic \
  --title 'chore: short summary' \
  --body-file /tmp/body.md \
  [--issue RHIDP-12345] \
  [--label ok-to-test] \
  [--dry-run]
```

Default is `--no-open` (no browser). Pass `--open` only for interactive agent runs.
`GITLAB_PIPELINE=true` forces no browser.

The script appends ` [<base>]` to `--title` when that suffix is missing, including
for `main` (`chore: short summary` becomes `chore: short summary [main]`). A
title that already ends with the base branch is left as-is.

Stdout includes `url: …`. Exit 0 if a PR/MR already exists for `--head`.

## Jira

| Condition | Behavior |
| --- | --- |
| `--issue KEY` or `JIRA_ISSUE` set + `JIRA_API_TOKEN` | After open, invoke `/rhdh-jira-link` (`link-pr-mr.js link`). The Jira comment is `PR: <url>` or `MR: <url>` (plus optional Adjusted fields). |
| Issue set but no token / missing link script | Warn; PR/MR still succeeds |
| No issue | `[INFO] no Jira issue; skip link` |

Override the link scripts directory with `RHDH_JIRA_LINK_SCRIPTS` when the
sibling skill is not next to this one in the pack checkout.

## Agents

1. Follow `/mutation-gate` for push + open (+ link if issuing).
2. Invoke `/rhdh-pr-mr` by name (or run the script path when already inside a
   skill clone). Pass `--issue` when the conversation already has a Jira key.
3. Report the `url:` line.

## Tests

```bash
bash -n "$SKILL/scripts/create-pr-mr.sh"
shellcheck --severity=warning "$SKILL/scripts/create-pr-mr.sh"
"$SKILL/scripts/create-pr-mr.sh" --help
"$SKILL/tests/smoke.sh"
```

## Completion

Done when the topic branch is pushed, a PR or MR URL is printed, and either a
Jira Web link was updated or linking was explicitly skipped for lack of an issue.

From redhat-developer/rhdh-skills, Apache-2.0.

More from redhat-developer/rhdh-skills

Signals

Stars
18
Forks
40
Open issues
1
Last commit (this folder)
Oct 8, 2026 (20 days ago)

From GitHub (fetched Oct 24, 2026).

Details

License
Apache-2.0
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from redhat-developer

Cite this page

rhdh-pr-mr skill. Agent Mart. https://agentmart.dev/skills/redhat-developer-rhdh-pr-mr (last updated 2026-10-24)