MCPcopy
hub / github.com/wshobson/agents / _detect_target

Function _detect_target

plugins/plugin-eval/src/plugin_eval/cli.py:23–29  ·  view source on GitHub ↗

Return 'skill' if SKILL.md exists, 'plugin' if .claude-plugin/ exists, else 'unknown'.

(path: Path)

Source from the content-addressed store, hash-verified

21
22
23def _detect_target(path: Path) -> str:
24 """Return 'skill' if SKILL.md exists, 'plugin' if .claude-plugin/ exists, else 'unknown'."""
25 if (path / "SKILL.md").exists():
26 return "skill"
27 if (path / ".claude-plugin").exists():
28 return "plugin"
29 return "unknown"
30
31
32def _run_score(

Callers 1

_run_scoreFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected