Continuing a pull request: merge the default branch first, resolving conflicts #33

Merged
dario merged 1 commit from dario/merge-default into main 2026-11-20 11:17:54 +01:00 AGit
Owner

Summary

  • When implement-issue continues its own pull request (#30), the skill now has the agent bring the branch up to date first: git merge origin/<default branch>. Git reports conflicts itself, so the prompt needs no file list.
    • Conflicts: resolve each listed file so both sides survive, git add, git commit.
    • Unsure how to resolve: git merge --abort, then ask (interactive) or comment on the pull request and finish.
    • Never rebase: push_branch does not force-push.
    • The tests run after the merge, so they show what the pull request would merge.
  • git merge (including --abort) joins the local commands every writing task may run, for Claude Code and OpenCode. Read-only tasks don't get it.

Evidence

  • The factory's pull request for #27 conflicts with main in docs/developing-the-factory.md after #29. Nothing told the agent how to handle that, and git merge was only allowed because the factory-dev sandbox permits every command (allowed_shell: ["*"]).

Test evidence

  • just check: passes.
  • internal/harness: writing runs allow git merge * (Claude Code and OpenCode); read-only runs don't.

Open questions

  • None.

🤖 Generated with Claude Code

## Summary - When `implement-issue` continues its own pull request (#30), the skill now has the agent bring the branch up to date first: `git merge origin/<default branch>`. Git reports conflicts itself, so the prompt needs no file list. - Conflicts: resolve each listed file so both sides survive, `git add`, `git commit`. - Unsure how to resolve: `git merge --abort`, then ask (interactive) or comment on the pull request and finish. - Never rebase: `push_branch` does not force-push. - The tests run after the merge, so they show what the pull request would merge. - `git merge` (including `--abort`) joins the local commands every writing task may run, for Claude Code and OpenCode. Read-only tasks don't get it. ## Evidence - The factory's pull request for #27 conflicts with `main` in `docs/developing-the-factory.md` after #29. Nothing told the agent how to handle that, and `git merge` was only allowed because the `factory-dev` sandbox permits every command (`allowed_shell: ["*"]`). ## Test evidence - `just check`: passes. - `internal/harness`: writing runs allow `git merge *` (Claude Code and OpenCode); read-only runs don't. ## Open questions - None. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
When implement-issue continues its own pull request (#30), the skill now
has the agent merge origin/<default branch> into the branch before
changing anything: git reports conflicts itself, so the prompt needs no
file list. It resolves them keeping both sides, or aborts and asks or
comments when unsure; it never rebases, since push_branch does not
force-push; and it runs the tests after the merge. git merge (and
git merge --abort) join the local commands every writing task may run.

Evidence: the factory's pull request for #27 conflicts with main in
docs/developing-the-factory.md after #29; nothing told the agent how to
handle it, and git merge was only allowed because factory-dev permits
every command.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
dario merged commit 1106325711 into main 2026-11-20 11:17:54 +01:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
dario/factory!33
No description provided.