From 541f983def407f1f2a3ebed859e37d9f00c83111 Mon Sep 17 00:00:00 2001 From: Qrius Date: Thu, 26 Sep 2024 00:11:05 +0200 Subject: Initial commit --- src/macro_processor/main.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 src/macro_processor/main.rs (limited to 'src/macro_processor/main.rs') diff --git a/src/macro_processor/main.rs b/src/macro_processor/main.rs new file mode 100644 index 0000000..5575aa6 --- /dev/null +++ b/src/macro_processor/main.rs @@ -0,0 +1,12 @@ +use std::env; +use std::fs; +use skaldpress::macro_processor::MacroProcessor; + +fn main() { + let args: Vec = env::args().collect(); + let input_file = fs::read_to_string(&args[1]).expect("Failed to read input file"); + + let mut macro_processor = MacroProcessor::new(); + let final_output = macro_processor.process_input(&input_file); + println!("{}", final_output); +} -- cgit v1.2.3