mirror of
https://github.com/bootandy/dust.git
synced 2026-06-08 11:29:05 +03:00
Change red ANSI color code for size of biggest file
The enum variant `ansi_term::Colour::Red` (which uses the ANSI color code `31`) is used instead of the code `196` to display the size of the largest file. This means that the red color of the terminal theme is used which is probably preferred by most users.
This commit is contained in:
+2
-2
@@ -2,7 +2,7 @@ extern crate ansi_term;
|
|||||||
|
|
||||||
use crate::utils::Node;
|
use crate::utils::Node;
|
||||||
|
|
||||||
use self::ansi_term::Colour::Fixed;
|
use self::ansi_term::Colour::Red;
|
||||||
use lscolors::{LsColors, Style};
|
use lscolors::{LsColors, Style};
|
||||||
|
|
||||||
use terminal_size::{terminal_size, Height, Width};
|
use terminal_size::{terminal_size, Height, Width};
|
||||||
@@ -298,7 +298,7 @@ pub fn format_string(
|
|||||||
};
|
};
|
||||||
|
|
||||||
let pretty_size = if is_biggest && display_data.colors_on {
|
let pretty_size = if is_biggest && display_data.colors_on {
|
||||||
format!("{}", Fixed(196).paint(pretty_size))
|
format!("{}", Red.paint(pretty_size))
|
||||||
} else {
|
} else {
|
||||||
pretty_size
|
pretty_size
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user