Skip to content

Commit

Permalink
fix(fish): Emit clear-screen escape sequence only in left prompt (sta…
Browse files Browse the repository at this point in the history
  • Loading branch information
rashil2000 authored Feb 14, 2022
1 parent e01abaa commit e9e090e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/print.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ pub fn get_prompt(context: Context) -> String {

// A workaround for a fish bug (see #739,#279). Applying it to all shells
// breaks things (see #808,#824,#834). Should only be printed in fish.
if let Shell::Fish = context.shell {
if Shell::Fish == context.shell && context.target == Target::Main {
buf.push_str("\x1b[J"); // An ASCII control code to clear screen
}

Expand Down

0 comments on commit e9e090e

Please sign in to comment.