add --title flag to opencode run (#3507)

This commit is contained in:
Aiden Cline
2025-10-28 13:32:36 -05:00
committed by GitHub
parent 1309ca7a81
commit 37380e1f94
3 changed files with 27 additions and 4 deletions

View File

@@ -1703,6 +1703,7 @@ export namespace SessionPrompt {
modelID: string
}) {
if (input.session.parentID) return
if (!Session.isDefaultTitle(input.session.title)) return
const isFirst =
input.history.filter((m) => m.info.role === "user" && !m.parts.every((p) => "synthetic" in p && p.synthetic))
.length === 1