bitsy-parser/src/bin/bitsy-validate.rs

14 lines
308 B
Rust
Raw Normal View History

2020-04-19 07:34:11 +01:00
extern crate bitsy_parser;
use bitsy_parser::game::Game;
use std::{env, fs};
fn main() {
let input_file = env::args()
.nth(1)
2020-04-24 18:20:05 +01:00
.expect("No input path specified. Usage: `bitsy-validate filepath`");
2020-04-19 07:34:11 +01:00
Game::from(fs::read_to_string(input_file).unwrap()).unwrap();
println!("OK!");
}