1#![deny(clippy::use_self)]
2use base::{App, AppCommand};
3use cli::parse_args;
4use print_game::print_game;
5use simulate::run_simulation;
6
7mod base;
8mod cli;
9mod log;
10mod print_game;
11mod simulate;
12
13#[tokio::main]
14async fn main() {
15 let mut app = App::new();
16
17 parse_args(&mut app).await;
18
19 let command = app.command.clone().unwrap();
20
21 match command {
22 AppCommand::Simulate(opts) => {
23 run_simulation(opts).await;
24 }
25 AppCommand::PrintGame(opts) => {
26 print_game(opts).await.unwrap_or_else(|e| {
27 println!("Error: {:?}", e);
28 });
29 }
30 }
31}