Engineering
Backport a fix to a release branch
Mention Merlin on a merged pull request and name a release branch. It cherry-picks the fix, runs the tests and opens the backport pull request.
@Merlin from now on, when someone asks you to backport a merged pull request in this repository, cherry-pick its commits onto the release branch they name and run the tests. Open a backport pull request into that branch and link it in your reply. If the cherry-pick conflicts or the tests fail, explain what broke in your reply instead of guessing a fix.
- Starts whenSomeone mentions
@usemerlin-aion a merged pull request and names the release branch Merlin worksClaude Code or Codex cherry-picks the fix onto that branch and runs the tests on a teammate's machine
- You getA backport pull request into the release branch, linked in a reply on the original
Tools
- GitHub
Capabilities
- Integrations
How it works
From a merged fix to a backport pull request.
Mention
@usemerlin-aion the merged pull request and name the release branch that needs the fix.Claude Code or Codex cherry-picks the commits onto the release branch on a teammate's machine and runs the tests there.
The reply links a backport pull request into the release branch. If a cherry-pick conflicts or a test fails, the reply explains what broke instead.
Mention @usemerlin-ai on the merged pull request and name the release branch that needs the fix.
Claude Code or Codex cherry-picks the commits onto the release branch on a teammate's machine and runs the tests there.
The reply links a backport pull request into the release branch. If a cherry-pick conflicts or a test fails, the reply explains what broke instead.
acme/web
Type/to searchSFix double charge when a card retry succeeds#612Code
Mergedsammerged 2 commits intomainfromfix/retry-double-charge
samcommented yesterdayAuthor
Stops the billing worker from charging again when Stripe reports a retried payment as succeeded.
Before and after
Fixes reach the release branch without a second round of work.
Without Merlin
Someone redoes the fix on the release branch by hand, often days after it merged.
- 01Find the merged commits
- 02Fetch the release branch
- 03Create a backport branch
- 04Cherry-pick each commit
- 05Resolve the conflicts
- 06Install the branch's dependencies
- 07Run the tests
- 08Push the branch
- 09Open a pull request into the release
- 10Link it on the original
With Merlin
One mention on the merged pull request gets the backport opened and tested.
@usemerlin-aion the merged pull requestWith the release branch namedCherry-picks and tests on Jo's MacBookClaude Code on the release branch
- Backport pull request openedLinked in a reply, or what broke
Setup
Connect GitHub once, then ask for a backport on any merged pull request.
Set these up once and anyone can ask for a backport from the merged pull request.
- 01Connect a machineRuntimeInstall the Merlin desktop app or CLI on a computer running Claude Code or Codex. You can also use a machine a teammate shares with your workspace.
- 02Install the GitHub appIntegrationsPick the repositories Merlin can access. It sees mentions, reads the pull request and replies in the thread. Pushes use the machine owner's own Git access.
- 03Keep release branches buildableRuntime
Older release branches can expect an older toolchain. Make sure the machine that runs the backport can install and test them, for example with the Node version each branch pins.
- 04Paste the setup promptGuidanceAn owner or admin sends the prompt below to @Merlin once, and it becomes workspace guidance for every future run.
Prompt
Tell Merlin how to handle a backport request.
@Merlin from now on, when someone asks you to backport a merged pull request in this repository, cherry-pick its commits onto the release branch they name and run the tests. Open a backport pull request into that branch and link it in your reply. If the cherry-pick conflicts or the tests fail, explain what broke in your reply instead of guessing a fix.
Once, when you paste it
- PromptYou paste the prompt to @Merlin
- GuidanceMerlin saves your rules as workspace guidance
Every time someone mentions Merlin on GitHub
- IntegrationThe GitHub app spots the mention
- RuntimeMerlin picks an available machine
- ContextThe run gathers context
- WorkClaude Code or Codex cherry-picks the fix and runs the tests
- SteeringYour team steers the work in the thread
- ResultMerlin links the backport pull request
Related use cases
More engineering tasks you can hand to Merlin.
- Integrations
Engineering
Rebase a pull request and fix the conflicts
Mention Merlin on a pull request that conflicts with main. It rebases the branch, resolves the conflicts, runs the tests and pushes.
@usemerlin-aion a pull request with conflictsA rebased branch and a note on each conflict - IntegrationsSkills
Engineering
Fix a bug from a Linear issue
Delegate a triaged bug to Merlin. It writes a failing test first, fixes the bug on a teammate's machine and links the pull request on the issue.
Bug issue delegated to MerlinPull request linked on the issue - IntegrationsSkills
Engineering
Fix a red CI run
Mention Merlin on a pull request with a failing check. It reads the job log, reproduces the failure and pushes a fix, or shows why the test is flaky.
@usemerlin-aion a pull request with a red checkA fix commit, or a flake verdict with evidence
Bring your coding agents into the tools your team already uses.
Let your whole team hand work to Claude Code and Codex today. Connect one machine and add Merlin to Slack, Linear or GitHub. 14-day free trial, no API keys, no card.