gpt/src/main.rs
2025-05-24 23:19:30 +09:00

29 lines
600 B
Rust

// main.rs
mod cli;
mod config;
mod mcp;
use cli::{Args, Commands, ServerCommands};
use clap::Parser;
#[tokio::main]
async fn main() {
let args = Args::parse();
match args.command {
Commands::Server { command } => {
match command {
ServerCommands::Setup => {
mcp::server::setup();
}
ServerCommands::Run => {
mcp::server::run().await;
}
}
}
Commands::Chat { message } => {
mcp::server::chat(&message).await;
}
}
}