25 lines
415 B
Rust
25 lines
415 B
Rust
use config::CuddleConfig;
|
|
|
|
mod actions;
|
|
mod cli;
|
|
mod config;
|
|
mod context;
|
|
mod model;
|
|
|
|
fn main() -> anyhow::Result<()> {
|
|
init_logging()?;
|
|
|
|
let config = CuddleConfig::from_env()?;
|
|
|
|
let context = context::extract_cuddle(config.clone())?;
|
|
_ = cli::CuddleCli::new(context)?.execute()?;
|
|
|
|
Ok(())
|
|
}
|
|
|
|
fn init_logging() -> anyhow::Result<()> {
|
|
tracing_subscriber::fmt().pretty().init();
|
|
|
|
Ok(())
|
|
}
|