id_effect_cli 0.3.0

CLI helpers for id_effect: optional clap, Exit/Cause → ExitCode, tracing init, run_main
Documentation
//! Generated by `id-effect new {{name}}`.

use clap::Parser;
use id_effect_cli::{RunMainConfig, run_main};

#[derive(Parser, Debug)]
#[command(name = "{{name}}", about = "id_effect application stub")]
struct Cli {
  /// Greet this name.
  #[arg(long, default_value = "world")]
  greet: String,
}

fn main() -> std::process::ExitCode {
  let cli = Cli::parse();
  let effect = id_effect::succeed::<(), (), ()>(()).map(move |_| {
    println!("hello, {}!", cli.greet);
  });
  run_main(effect, (), RunMainConfig::minimal())
}