diff options
author | sharkdp <davidpeter@web.de> | 2020-04-22 20:35:05 +0200 |
---|---|---|
committer | David Peter <sharkdp@users.noreply.github.com> | 2020-04-22 23:55:28 +0200 |
commit | 36dde9275af3f513b77395a92a0023f7e6134fa6 (patch) | |
tree | c78b084b3aafdc9b5748e16acd097c623a6efef9 /examples | |
parent | a8f759c0809fab3839c01e83440700740601f246 (diff) |
Simplify style_components
Diffstat (limited to 'examples')
-rw-r--r-- | examples/cat.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/cat.rs b/examples/cat.rs index 5111a086..ac653697 100644 --- a/examples/cat.rs +++ b/examples/cat.rs @@ -1,16 +1,16 @@ /// A very simple colorized `cat` clone, using `bat` as a library. /// See `src/bin/bat` for the full `bat` application. -use bat::{PrettyPrinter, StyleComponent, StyleComponents}; +use bat::{PrettyPrinter, StyleComponent}; use console::Term; fn main() { PrettyPrinter::new() .term_width(Term::stdout().size().1 as usize) - .style_components(StyleComponents::new(&[ + .style_components(&[ StyleComponent::Header, StyleComponent::Grid, StyleComponent::Numbers, - ])) + ]) .input_files(std::env::args_os().skip(1)) .print() .expect("no errors"); |