use std::path::PathBuf;
use super::{Harness, InstallHookError, json_hooks};
use crate::utils::home_dir;
#[derive(Debug, Clone, Copy, Default)]
pub struct Ccode;
impl Ccode {
#[must_use]
pub fn new() -> Self {
Self {}
}
}
impl Harness for Ccode {
fn name(&self) -> &'static str {
"claude-code"
}
fn alias_names(&self) -> &'static [&'static str] {
&["claude"]
}
async fn install_hooks(&self) -> Result<PathBuf, InstallHookError> {
let config_path = home_dir().join(".claude").join("settings.json");
json_hooks::install(&config_path, "^Bash$", "atuin hook claude-code").await?;
Ok(config_path)
}
}