Work a task through to merged PR
Table of Contents
This page documents a runbook — a named, repeatable composition of recipes and skills for a complete multi-step procedure. Each step references a recipe or skill by id-link.
Goal
Take an existing task from BACKLOG through implementation, PR creation, review rounds, and merge — the full development lifecycle.
Preconditions
- A task exists in the current sprint with
#+type: task,State: BACKLOG. - The task's story is
STARTEDin the sprint. - You are on
mainor can create a fresh feature branch. ghCLI is authenticated;SSH_AUTH_SOCKis exported (see SSH memory).
Steps
In execution order:
Clock on. Run
compass task startwith the task's slug to switch branch, mark the taskSTARTED, and stamp the session journal:./projects/ores.compass/compass.sh task start <task-slug>
A task with no
#+branch:(scaffolded viacompass add taskor born as a story's first real task) getsfeature/<slug-kebab>derived automatically, created off freshorigin/main;--branchoverrides:./projects/ores.compass/compass.sh task start <task-slug> --branch <override>
This covers all three cases: new task on an existing story, resuming a BACKLOG task, and restarting an already-STARTED task after a session reset. Read
task_<slug>.orgafter clocking on: understand the* Goal,* Acceptancecriteria, and* Notes. (pr createsets#+pr:later.)- Sync with main.
compass pr sync— fetch, rebase, report; on conflicts it stops with the conflicted files and the ways out. If you are onmain, create a feature branch first: see How do I start work on a story?. - Implement. Do the actual work: write code, documents, or configuration. Follow the conventions in LLM instructions for code style, documentation, and testing.
- Commit. Use ORE Studio commit conventions:
[component] Imperative summarywith aCo-Authored-By:trailer. One logical change per commit. Never amend commits on a branch under review. - Open a PR.
compass pr createper How do I create a PR? — it pushes, builds the body with Traceability, records the PR on the task, and stamps the journal. - Monitor CI. Wait for checks to pass. If a check fails, follow How do I fix a failing CI check?.
Handle review. When review comments arrive, follow How do I address PR review comments?:
- Sync with
mainfirst (rebase). - Decide accept/decline per comment.
- Apply fixes (one commit per logical fix).
- Push, reply to every comment, resolve threads.
- Record the review round in the task's
* Reviewtable.
Repeat step 7 for each review round until the PR is approved.
- Sync with
Close out — before the merge. When the final review round is done and the PR delivers this task, end the bookkeeping on the PR branch so it rides the PR — never a follow-up PR:
./projects/ores.compass/compass.sh task done <slug>
Task and story row flip to DONE with end date. Write the task's
* Resultby hand, distill any* Planinto the parent story's* Decisions, commit, and push. A task spanning several PRs stays open — close it on the PR that completes it.Sync story and sprint state. If this was the final task in the story, update both files in the same commit — still before the merge, so the sync rides the PR too:
a. In the story.org
* Statustable: state →DONE, setNowtoNothing., fillEnddate. b. In the sprint.org* Storiestable: update the story row toDONEand fill theEndcolumn.Both files must stay in sync. A story marked
DONEinstory.orgbutSTARTEDorBACKLOGinsprint.orgis a silent inconsistency that the sprint health review will not catch automatically.- Merge.
compass pr merge— the guards refuse while threads are unresolved or CI is not green; merge never touches task state (a STARTED task only draws a warning), retries GitHub's transient base-branch-modified race, and deletes the remote branch. See How do I merge a PR?.
Postconditions
- Task is
DONEwith* Resultfilled, and the close-out commit is inside the merged PR. - PR is merged into
main. - Review rounds are recorded in the task's
* Reviewtable. - Parent story reflects any decisions from the task's
* Plan. - If the story is complete:
story.organdsprint.orgboth showDONEwith matching end dates.
See also
- How do I start work on a story? — branch creation and STARTED transition.
- How do I monitor a PR until green? — the CI waiting loop.
- How do I merge a PR? — close it out.
- Start work on a new story — the preceding runbook for the story-scaffold phase.
- Runbook glossary entry — what a runbook is and how to create one.