Skip to content

Commit e61be1e

Browse files
authored
Use cargo styling in main --help resources section (#482)
In #457 I switched the "after help" messages to use Cargo's styling, but forgot to update the message for `bevy --help`. This PR fixes that so the "Resources" section in `bevy --help` is consistent. Before and after: <img width="908" alt="image" src="https://github.com/user-attachments/assets/a9fcc525-66ac-4b15-bc3f-2b2451faae47" />
1 parent e6985fb commit e61be1e

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

src/bin/main.rs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -82,21 +82,22 @@ pub struct Cli {
8282
fn after_help() -> String {
8383
let mut message = String::new();
8484

85-
let header = Style::new().bold().underline();
86-
let bold = Style::new().bold();
85+
let header = style::HEADER;
86+
let literal = style::LITERAL;
87+
let underline = Style::new().underline();
8788

8889
_ = writeln!(message, "{header}Resources:{header:#}");
8990
_ = writeln!(
9091
message,
91-
" {bold}Bevy Website{bold:#} https://bevyengine.org"
92+
" {literal}Bevy Website{literal:#} {underline}https://bevyengine.org{underline:#}"
9293
);
9394
_ = writeln!(
9495
message,
95-
" {bold}Bevy Repository{bold:#} https://github.com/bevyengine/bevy"
96+
" {literal}Bevy Repository{literal:#} {underline}https://github.com/bevyengine/bevy{underline:#}"
9697
);
9798
_ = writeln!(
9899
message,
99-
" {bold}CLI Documentation{bold:#} https://thebevyflock.github.io/bevy_cli"
100+
" {literal}CLI Documentation{literal:#} {underline}https://thebevyflock.github.io/bevy_cli{underline:#}"
100101
);
101102

102103
message

0 commit comments

Comments
 (0)