Skip to content

Commit c56dd94

Browse files
authored
Merge pull request microsoft#158198 from microsoft/tyriar/158120
Collapse 3+ spaces into middle ellipsis
2 parents a575592 + a95252e commit c56dd94

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/vs/workbench/contrib/terminal/browser/terminalInstance.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -869,7 +869,12 @@ export class TerminalInstance extends Disposable implements ITerminalInstance {
869869
commandMap.add(executingCommand);
870870
}
871871
function formatLabel(label: string) {
872-
return label.replace(/\r?\n/g, '\u23CE');
872+
return label
873+
// Replace new lines with "enter" symbol
874+
.replace(/\r?\n/g, '\u23CE')
875+
// Replace 3 or more spaces with midline horizontal ellipsis which looks similar
876+
// to whitespace in the editor
877+
.replace(/\s\s\s+/g, '\u22EF');
873878
}
874879
if (commands && commands.length > 0) {
875880
for (const entry of commands) {

0 commit comments

Comments
 (0)