use anyhow::Result;
use clap::{Parser, Subcommand};
use seqtkrs::commands;
#[derive(Parser, Debug)]
#[command(name = "seqtkrs")]
#[command(about = "快速轻量的生物序列处理工具集", long_about = None)]
#[command(version)]
struct Cli {
#[command(subcommand)]
command: Commands,
}
#[derive(Subcommand, Debug)]
enum Commands {
Seq(commands::seq::SeqArgs),
Sample(commands::sample::SampleArgs),
Subseq(commands::subseq::SubseqArgs),
Trimfq(commands::trimfq::TrimfqArgs),
Fqchk(commands::fqchk::FqchkArgs),
Comp(commands::comp::CompArgs),
Mergepe(commands::mergepe::MergepeArgs),
Dropse(commands::dropse::DropseArgs),
Split(commands::split::SplitArgs),
Rename(commands::rename::RenameArgs),
Mutfa(commands::mutfa::MutfaArgs),
Mergefa(commands::mergefa::MergefaArgs),
Famask(commands::famask::FamaskArgs),
Gc(commands::gc::GcArgs),
Hety(commands::hety::HetyArgs),
Cutn(commands::cutn::CutnArgs),
Gap(commands::gap::GapArgs),
Hpc(commands::hpc::HpcArgs),
Hrun(commands::hrun::HrunArgs),
Telo(commands::telo::TeloArgs),
Kfreq(commands::kfreq::KfreqArgs),
Listhet(commands::listhet::ListhetArgs),
Randbase(commands::randbase::RandbaseArgs),
Size(commands::size::SizeArgs),
}
fn main() -> Result<()> {
let cli = Cli::parse();
match cli.command {
Commands::Seq(args) => commands::seq::run(&args),
Commands::Sample(args) => commands::sample::run(&args),
Commands::Subseq(args) => commands::subseq::run(&args),
Commands::Trimfq(args) => commands::trimfq::run(&args),
Commands::Fqchk(args) => commands::fqchk::run(&args),
Commands::Comp(args) => commands::comp::run(&args),
Commands::Mergepe(args) => commands::mergepe::run(&args),
Commands::Dropse(args) => commands::dropse::run(&args),
Commands::Split(args) => commands::split::run(&args),
Commands::Rename(args) => commands::rename::run(&args),
Commands::Mutfa(args) => commands::mutfa::run(&args),
Commands::Mergefa(args) => commands::mergefa::run(&args),
Commands::Famask(args) => commands::famask::run(&args),
Commands::Gc(args) => commands::gc::run(&args),
Commands::Hety(args) => commands::hety::run(&args),
Commands::Cutn(args) => commands::cutn::run(&args),
Commands::Gap(args) => commands::gap::run(&args),
Commands::Hpc(args) => commands::hpc::run(&args),
Commands::Hrun(args) => commands::hrun::run(&args),
Commands::Telo(args) => commands::telo::run(&args),
Commands::Kfreq(args) => commands::kfreq::run(&args),
Commands::Listhet(args) => commands::listhet::run(&args),
Commands::Randbase(args) => commands::randbase::run(&args),
Commands::Size(args) => commands::size::run(&args),
}
}