Artificial Intelligence
Please fill the required field.

wodemo leeks


.toml # загрузить leeks.toml use std::{env::args, fs::File}; // хорошим тоном считается объявлять модули mod leeksfile; fn main() { let args = args().skip(1); match args.collect::<Vec<String>>().as_slice() { ["leeks.toml", name] => { let src = leeksfile::LeeksFile::from_toml(&File::open(name).unwrap()); let src = src.unwrap(); let (rlib, ulib, result) = leeksfile::build_tasks(src.tasks); println!("C++ build argv:"); for arg in rlib { println!("{}", arg); } println!("Rust build argv:"); for arg in ulib { println!("{}", arg); } println!("Result build argv:"); for arg in result { println!("{}", arg); } }, _ => { eprintln!("Try `leeks <filename>` or `leeks (if exist) <filename>`");