Let the agent set the merge commit title, defaulting to the task title

This commit is contained in:
Ian Gulliver
2026-10-14 21:21:54 -07:00
parent 73f6dd73d2
commit 01c60d6618
24 changed files with 373 additions and 202 deletions
+4 -1
View File
@@ -125,7 +125,7 @@ export function mountTranscript(root: HTMLElement): () => void {
confirmChanges(
task,
(u) =>
`Merge "${task.title}" into ${target}? The agent first merges ${target} in and resolves any conflicts; when that turn ends, ${changesText(u)} become one commit on ${target} and the task closes. Nothing is pushed.`,
`Merge "${task.title}" into ${target}? The agent first merges ${target} in and resolves any conflicts; when that turn ends, ${changesText(u)} become one commit on ${target} titled "${task.merge_title}", and the task closes. Nothing is pushed.`,
async () => {
await post("/api/tasks/{taskId}/merge", { path: { taskId: task.id } });
},
@@ -700,6 +700,9 @@ function renderEvent(ev: ByreEvent, ctx: Ctx): HTMLElement | null {
return null;
}
case "task.merge_title":
return h("div", { class: "note" }, `${ev.actor} set the merge commit title to "${String(p["merge_title"])}" `, when);
case "task.merged":
return h("div", { class: "note" }, `${ev.actor} merged the task${p["commit"] ? ` as ${String(p["commit"]).slice(0, 7)}` : ""} `, when);