mod cli; mod completions; mod dashboard; mod grep; mod logparse; mod stats; mod sysinfo_mod; use anyhow::Result; use clap::Parser; use cli::{Cli, Comandos}; fn main() -> Result<()> { let cli = Cli::parse(); match &cli.comando { Comandos::Stats { archivo } => stats::ejecutar(archivo), Comandos::Logparse { nivel, quiet, archivo } => { logparse::ejecutar(archivo, nivel, *quiet) } Comandos::Sysinfo { formato } => sysinfo_mod::ejecutar(formato), Comandos::Grep { patron, ignorar_mayusculas, archivo } => { grep::ejecutar(patron, *ignorar_mayusculas, archivo) } Comandos::Dashboard { watch } => dashboard::ejecutar(*watch), Comandos::Completions { shell } => completions::ejecutar(shell), } }