Skip to main content

rippy_cli/setup/
mod.rs

1mod claude_code;
2mod cursor;
3mod gemini;
4mod json_settings;
5mod tokf;
6
7use std::process::ExitCode;
8
9use crate::cli::{SetupArgs, SetupTarget};
10use crate::error::RippyError;
11
12/// Run a setup subcommand.
13///
14/// # Errors
15///
16/// Returns `RippyError::Setup` if the target tool is not installed or
17/// configuration cannot be written.
18pub fn run(args: &SetupArgs) -> Result<ExitCode, RippyError> {
19    match &args.target {
20        SetupTarget::Tokf(a) => tokf::run(a),
21        SetupTarget::ClaudeCode(a) => claude_code::run(a),
22        SetupTarget::Gemini(a) => gemini::run(a),
23        SetupTarget::Cursor(a) => cursor::run(a),
24    }
25}