mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-06 00:12:11 +00:00
fix(desktop): Stream bash output + strip-asni (#8961)
This commit is contained in:
parent
6e020ef9ef
commit
c325aa1142
3 changed files with 4 additions and 1 deletions
|
|
@ -10,6 +10,7 @@ import {
|
|||
onCleanup,
|
||||
type JSX,
|
||||
} from "solid-js"
|
||||
import stripAnsi from "strip-ansi"
|
||||
import { Dynamic } from "solid-js/web"
|
||||
import {
|
||||
AgentPart,
|
||||
|
|
@ -926,7 +927,7 @@ ToolRegistry.register({
|
|||
>
|
||||
<div data-component="tool-output" data-scrollable>
|
||||
<Markdown
|
||||
text={`\`\`\`command\n$ ${props.input.command ?? props.metadata.command ?? ""}${props.output ? "\n\n" + props.output : ""}\n\`\`\``}
|
||||
text={`\`\`\`command\n$ ${props.input.command ?? props.metadata.command ?? ""}${props.output || props.metadata.output ? "\n\n" + stripAnsi(props.output || props.metadata.output) : ""}\n\`\`\``}
|
||||
/>
|
||||
</div>
|
||||
</BasicTool>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue