Start parsing lines

This commit is contained in:
Joscha 2021-11-17 22:40:11 +01:00
parent f6c249393b
commit 2a1560cfb9
3 changed files with 117 additions and 0 deletions

16
src/parse.rs Normal file
View file

@ -0,0 +1,16 @@
use std::fs;
use std::path::Path;
use crate::commands::Command;
use self::line::parse_lines;
mod line;
pub fn parse(file: &Path) -> anyhow::Result<Vec<Command>> {
let content = fs::read_to_string(file)?;
let lines = parse_lines(&content)?;
println!("{:#?}", lines);
todo!()
}