mod app; mod config; mod emby; mod login; mod player; mod ui; use anyhow::Result; use clap::Parser; #[tokio::main] async fn main() -> Result<()> { let args = config::CliArgs::parse(); let (cfg, save_target) = config::load(&args)?; let cfg = match cfg { Some(c) => c, None => { // Interactive credential prompt in the TUI login::prompt(save_target.as_deref())? } }; let client = emby::Client::new(&cfg).await?; let mut app = app::App::new(client).await?; ui::run(&mut app).await?; Ok(()) }