mirror of https://github.com/zkat/miette.git
fix: set correct field in MietteHandlerOpts::ansi_colors
Thanks for miette! We've been having a great time using it in cargo-nextest to print out nicely-formatted errors. I noticed a bug while testing out miette -- the `ansi_colors` method does not set ANSI colors properly. By the way, I do not believe miette should use RGB colors at all -- default colors in applications must be restricted to 12 ANSI colors. See https://rust-cli-recommendations.sunshowers.io/colors.html#color-palettes for why. I'm happy to disable RGB colors in all the applications I maintain, but doing so globally is something for upstream to consider.
This commit is contained in:
parent
bd8f8e31ae
commit
f2ebc1628b
|
|
@ -93,7 +93,7 @@ impl MietteHandlerOpts {
|
|||
|
||||
/// If true, ANSI colors will be used during graphical rendering.
|
||||
pub fn ansi_colors(mut self, color: bool) -> Self {
|
||||
self.rgb_colors = Some(color);
|
||||
self.ansi_colors = Some(color);
|
||||
self
|
||||
}
|
||||
/// If true, graphical rendering will be used regardless of terminal
|
||||
|
|
|
|||
Loading…
Reference in New Issue