MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / is_installed_in

Method is_installed_in

atomic-agent/src/hooks/gemini_cli.rs:476–492  ·  view source on GitHub ↗

Check if Atomic hooks are installed in a settings file.

(settings_path: &Path)

Source from the content-addressed store, hash-verified

474
475 /// Check if Atomic hooks are installed in a settings file.
476 fn is_installed_in(settings_path: &Path) -> bool {
477 if !settings_path.exists() {
478 return false;
479 }
480
481 match Self::read_settings(settings_path) {
482 Ok((_, hooks)) => {
483 has_any_atomic_hook(&hooks.session_start)
484 || has_any_atomic_hook(&hooks.session_end)
485 || has_any_atomic_hook(&hooks.before_agent)
486 || has_any_atomic_hook(&hooks.after_agent)
487 || has_any_atomic_hook(&hooks.before_tool)
488 || has_any_atomic_hook(&hooks.after_tool)
489 }
490 Err(_) => false,
491 }
492 }
493
494 // Global install/uninstall (same pattern as Claude Code)
495

Callers

nothing calls this directly

Calls 3

read_settingsFunction · 0.85
has_any_atomic_hookFunction · 0.70
existsMethod · 0.45

Tested by

no test coverage detected