#[allow(dead_code)]
mod configotron;

use configotron::conf::read_and_parse_yaml_file;
use configotron::doc::grid::{create_ascii_doc_string, DocGrid};

fn main() {
    let data = match read_and_parse_yaml_file("example.yml") {
        Ok(d) => d,
        Err(error) => {
            println!("{}", error);
            return;
        }
    };

    let grid: DocGrid = DocGrid::from(&data);
    let ascii_docs = create_ascii_doc_string(&grid);
    println!("{}", ascii_docs);

    println!("Done!");
}
