Detect which registered agents are present in the given repository. Calls `detect_presence()` on each registered agent and returns the names of agents that are detected. # Example ```rust,no_run use atomic_agent::hooks::AgentRegistry; use std::path::Path; let registry = AgentRegistry::with_defaults(); let detected = registry.detect(Path::new("/path/to/repo")); for name in detected { println!("
(&self, repo_root: &Path)
| 390 | /// } |
| 391 | /// ``` |
| 392 | pub fn detect(&self, repo_root: &Path) -> Vec<&str> { |
| 393 | self.agents |
| 394 | .iter() |
| 395 | .filter(|a| a.detect_presence(repo_root)) |
| 396 | .map(|a| a.name()) |
| 397 | .collect() |
| 398 | } |
| 399 | |
| 400 | /// Returns all agents that have hooks currently installed. |
| 401 | pub fn installed(&self, repo_root: &Path) -> Vec<&str> { |