Skip to content

Commit df70077

Browse files
krallinfacebook-github-bot
authored andcommitted
buck2: don't output stdout in red for no reason
Summary: We leave stderr in whatever color we received it in, but for some reason we print stdout in red. This is rather confusing. Don't do that. Reviewed By: lmvasquezg Differential Revision: D47231602 fbshipit-source-id: 777c0558bb5418f2d569e02ed89524aa9b82e97b
1 parent 123af5b commit df70077

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

app/buck2_client_ctx/src/subscribers/superconsole.rs

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -831,10 +831,7 @@ fn lines_for_command_details(
831831
.with(Color::DarkRed)
832832
.attribute(Attribute::Bold),
833833
)]));
834-
lines.extend(Lines::from_multiline_string(
835-
&command_failed.stdout,
836-
color(Color::DarkRed),
837-
));
834+
lines.extend(Lines::from_colored_multiline_string(&command_failed.stdout));
838835
lines.push(Line::from_iter([Span::new_styled_lossy(
839836
"stderr:"
840837
.to_owned()
@@ -859,13 +856,6 @@ fn truncate(contents: &str) -> Option<String> {
859856
}
860857
}
861858

862-
fn color(color: Color) -> ContentStyle {
863-
ContentStyle {
864-
foreground_color: Some(color),
865-
..Default::default()
866-
}
867-
}
868-
869859
#[cfg(test)]
870860
mod tests {
871861
use std::time::SystemTime;

0 commit comments

Comments
 (0)