Replace newlines with spaces in prompt display

This commit is contained in:
Chris Wanstrath 2026-02-21 07:51:20 -08:00
parent ed43aaff78
commit cc1d2628a9

View File

@ -67,7 +67,7 @@ export async function action(opts: { json?: boolean }) {
console.log(` ${dim}${"BRANCH".padEnd(branchWidth)} PROMPT${reset}`)
for (const s of sessions) {
const prompt = s.prompt ?? ""
const prompt = (s.prompt ?? "").replace(/\n/g, " ")
const status = statuses[s.branch]
const icon = icons[status]
const bc = branchColors[status]