| 109 | } |
| 110 | |
| 111 | fn log_tool_title_figlet(title: String) { |
| 112 | let small_font = include_str!("small.flf"); |
| 113 | let small_font_content = String::from(small_font); |
| 114 | |
| 115 | let small_font_file_name = "tmp.flf"; |
| 116 | |
| 117 | // create the font file to use, then delete it |
| 118 | let mut tmp_font_file = File::create(small_font_file_name).unwrap(); |
| 119 | write!(&mut tmp_font_file, "{}", small_font_content).unwrap(); |
| 120 | |
| 121 | let small_font = FIGfont::from_file(small_font_file_name).unwrap(); |
| 122 | let figure = small_font.convert(title.as_str()); |
| 123 | assert!(figure.is_some()); |
| 124 | println!("{}\n", figure.unwrap()); |
| 125 | |
| 126 | fs::remove_file(small_font_file_name).expect("Not able to delete tmp file"); |
| 127 | } |
| 128 | |
| 129 | fn log_header() { |
| 130 | println!("Version: {}", load_version()); |