diff --git a/packages/cli/src/ui/components/Footer.tsx b/packages/cli/src/ui/components/Footer.tsx index 5efc88056..95546fe70 100644 --- a/packages/cli/src/ui/components/Footer.tsx +++ b/packages/cli/src/ui/components/Footer.tsx @@ -128,9 +128,9 @@ export const Footer: React.FC = () => { - {/* Custom status line row */} + {/* Custom status line row — match footer's horizontal inset */} {statusLineText && ( - + {statusLineText} diff --git a/packages/cli/src/ui/hooks/useStatusLine.ts b/packages/cli/src/ui/hooks/useStatusLine.ts index 186aa189e..24cac528e 100644 --- a/packages/cli/src/ui/hooks/useStatusLine.ts +++ b/packages/cli/src/ui/hooks/useStatusLine.ts @@ -166,12 +166,14 @@ export function useStatusLine(): { const child = exec( cmd, - { timeout: 5000, maxBuffer: 1024 * 10 }, + { cwd: cfg.getTargetDir(), timeout: 5000, maxBuffer: 1024 * 10 }, (error, stdout) => { if (gen !== generationRef.current) return; // stale activeChildRef.current = undefined; if (!error && stdout) { - setOutput(stdout.trim().split('\n')[0] || null); + // Strip only the trailing newline to preserve intentional whitespace. + const line = stdout.replace(/\r?\n$/, '').split(/\r?\n/, 1)[0]; + setOutput(line || null); } else { setOutput(null); }