use anyhow::Result;
use clap::Parser;
use openfunctions_rs::cli::Cli;
use openfunctions_rs::core::Config;
#[tokio::main]
async fn main() -> Result<()> {
env_logger::init();
let cli = Cli::parse();
let config = Config::load(cli.config).await?;
if let Some(command) = cli.command {
command.execute(&config).await?;
} else {
Cli::parse_from(vec!["openfunctions", "--help"]);
}
Ok(())
}