Skip to content

Commit

Permalink
Fix style for Url and Command
Browse files Browse the repository at this point in the history
  • Loading branch information
Malax committed Dec 20, 2024
1 parent da00c86 commit fd6f74f
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions shared/src/output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,13 +154,15 @@ impl BuildpackOutputText {
match section {
BuildpackOutputTextSection::Regular(_) => {}
BuildpackOutputTextSection::Value(_) => {
result.push_str(ANSI_VALUE_CODE);
result.push(VALUE_DELIMITER_CHAR);
result.push_str(ANSI_VALUE_CODE);
}
BuildpackOutputTextSection::Url(_) => {
result.push(VALUE_DELIMITER_CHAR);
result.push_str(ANSI_URL_CODE);
}
BuildpackOutputTextSection::Command(_) => {
result.push(VALUE_DELIMITER_CHAR);
result.push_str(ANSI_COMMAND_CODE);
}
}
Expand All @@ -175,8 +177,13 @@ impl BuildpackOutputText {

result.push_str(&line_start);

if let BuildpackOutputTextSection::Value(_) = section {
result.push_str(ANSI_VALUE_CODE);
match section {
BuildpackOutputTextSection::Value(_)
| BuildpackOutputTextSection::Url(_)
| BuildpackOutputTextSection::Command(_) => {
result.push_str(ANSI_VALUE_CODE);
}
BuildpackOutputTextSection::Regular(_) => {}
}
} else {
result.push(char);
Expand Down

0 comments on commit fd6f74f

Please sign in to comment.