fix(tui): show elapsed time for running shell tools (#1026)

This commit is contained in:
paulbettner
2026-02-18 23:01:47 -05:00
committed by GitHub
parent 943c20a495
commit 674e8c12c2
2 changed files with 8 additions and 16 deletions

View File

@@ -68,6 +68,13 @@ export const StreamingOutputDisplay = memo(
{" "} +{hiddenCount} more lines ({elapsed}s){interruptHint}
</Text>
)}
{/* Always show elapsed while running, even if output is short */}
{hiddenCount === 0 && (
<Text dimColor>
{" "}({elapsed}s){interruptHint}
</Text>
)}
</Box>
);
},

View File

@@ -21,6 +21,7 @@ import {
isPatchTool,
isPlanTool,
isSearchTool,
isShellTool,
isTaskTool,
isTodoTool,
} from "../helpers/toolNameMapping.js";
@@ -62,22 +63,6 @@ type ToolCallLine = {
streaming?: StreamingState;
};
/**
* Check if tool is a shell/bash tool that supports streaming output
*/
function isShellTool(name: string): boolean {
const shellTools = [
"Bash",
"Shell",
"shell",
"shell_command",
"run_shell_command",
"RunShellCommand",
"ShellCommand",
];
return shellTools.includes(name);
}
/**
* ToolCallMessageRich - Rich formatting version with old layout logic
* This preserves the exact wrapping and spacing logic from the old codebase