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