(
output: Extract<
NonNullable<Extract<ToolResultContent, { kind: 'shell_run' }>['output']>,
{ mode: 'pipes' }
>,
width: number,
)
| 608 | } |
| 609 | |
| 610 | function renderPipeShellOutput( |
| 611 | output: Extract< |
| 612 | NonNullable<Extract<ToolResultContent, { kind: 'shell_run' }>['output']>, |
| 613 | { mode: 'pipes' } |
| 614 | >, |
| 615 | width: number, |
| 616 | ): string[] { |
| 617 | const lines: string[] = []; |
| 618 | if (output.stdout) lines.push(...renderCappedResultText(output.stdout, width)); |
| 619 | if (output.stderr) { |
| 620 | lines.push(...renderIndented(ansi.dim('[stderr]'), width, 2)); |
| 621 | lines.push(...renderCappedResultText(output.stderr, width, ansi.dim)); |
| 622 | } |
| 623 | return lines; |
| 624 | } |
| 625 | |
| 626 | /** |
| 627 | * Render a `shell_run` (background-process) result. The status line — status, |
no test coverage detected