mini: add quiet transcript settings (#38152)

This commit is contained in:
Simon Klee 2026-07-21 19:36:34 +02:00 committed by GitHub
commit dd6c95fdc7
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
22 changed files with 398 additions and 52 deletions

View file

@ -1273,7 +1273,11 @@ function shellOutput(command: string, raw: string): string | undefined {
return `\n${body}`
}
export function toolEntryBody(commit: StreamCommit, raw: string): RunEntryBody | undefined {
export function toolEntryBody(
commit: StreamCommit,
raw: string,
options?: { shellOutput?: boolean },
): RunEntryBody | undefined {
if (commit.shell) {
if (commit.phase === "start") {
return textBody(`$ ${commit.shell.command}`)
@ -1294,6 +1298,8 @@ export function toolEntryBody(commit: StreamCommit, raw: string): RunEntryBody |
const ctx = toolFrame(commit, raw)
const view = toolView(ctx.name)
if (ctx.name === "shell" && commit.phase === "progress" && options?.shellOutput === false) return undefined
if (ctx.name === "subagent") {
if (commit.phase === "start") {
return undefined