dinopkg/crates/dinopkg-cli/src/main.rs

15 lines
283 B
Rust
Raw Normal View History

2024-07-09 19:30:33 +00:00
use clap::Parser;
mod command;
2024-07-09 20:16:17 +00:00
use color_eyre::Result;
2024-07-09 19:43:00 +00:00
use command::{Cli, Command};
2024-07-09 19:30:33 +00:00
#[tokio::main]
2024-07-09 20:16:17 +00:00
async fn main() -> Result<()> {
2024-07-09 19:30:33 +00:00
let cli = Cli::parse();
2024-07-09 19:45:06 +00:00
match cli.command {
2024-07-09 20:16:17 +00:00
Command::Run { script_name } => command::run::run(script_name).await?,
2024-07-09 19:45:06 +00:00
}
2024-07-09 20:16:17 +00:00
Ok(())
2024-07-09 19:24:48 +00:00
}