cuddle-v2/crates/cuddle/src/main.rs

26 lines
407 B
Rust
Raw Normal View History

mod project;
use project::Project;
#[tokio::main]
async fn main() -> anyhow::Result<()> {
dotenv::dotenv().ok();
tracing_subscriber::fmt::init();
Cuddle::new().await?;
Ok(())
}
struct Cuddle {
project: Option<Project>,
}
impl Cuddle {
pub async fn new() -> anyhow::Result<Self> {
let project = Project::from_current_path().await?;
Ok(Self { project })
}
}