mirror of
https://github.com/sharkdp/bat.git
synced 2024-12-21 14:00:40 +01:00
Modifying changing config for efficiency
This commit is contained in:
parent
2e3784aa30
commit
f3dde0185d
@ -130,12 +130,11 @@ pub fn list_languages(assets: &HighlightingAssets, term_width: usize) {
|
|||||||
|
|
||||||
pub fn list_themes(assets: &HighlightingAssets, config: &mut Config) {
|
pub fn list_themes(assets: &HighlightingAssets, config: &mut Config) {
|
||||||
let themes = &assets.theme_set.themes;
|
let themes = &assets.theme_set.themes;
|
||||||
|
config.files = vec![Some("assets/hello.rs")];
|
||||||
for (theme, _) in themes.iter() {
|
for (theme, _) in themes.iter() {
|
||||||
println!("{}", theme);
|
println!("{}", theme);
|
||||||
config.theme = theme.to_string();
|
config.theme = theme.to_string();
|
||||||
config.files = vec![Some("assets/hello.rs")];
|
let _controller = Controller::new(&config, &assets).run();
|
||||||
let controller = Controller::new(&config, &assets);
|
|
||||||
let _res = controller.run();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user