Overview
When a ticket is approved and moves toDONE, its changes live on an isolated branch (goal/{goal_id}/ticket/{ticket_id}). Draft provides tools to merge these changes back into your main branch.
Merge Checklist
Before merging, Draft validates:- All verification commands passed
- The revision is approved
- No merge conflicts with the base branch
- The branch is up to date
Merging via the UI
- Open a
DONEticket - Click “Merge”
- Draft runs the merge checklist
- If all checks pass, the branch is merged
Merging via the API
Merge Strategy
Configure the merge strategy indraft.yaml:
| Strategy | Description |
|---|---|
merge | Create a merge commit (preserves full history) |
squash | Squash all commits into one (clean history) |
rebase | Rebase onto base branch (linear history) |
Pull Request Integration
Draft can create pull requests on GitHub/GitLab instead of direct merging:- Ticket title and description
- Diff summary
- Verification results
Handling Conflicts
If merge conflicts are detected:- The merge checklist flags the conflict
- You can resolve manually in the worktree
- Or send the ticket back to
EXECUTINGfor the agent to resolve