MCPcopy
hub / github.com/openai/plugins / shell_tool_command

Function shell_tool_command

plugins/ngs-analysis/scripts/ngs_run_utils.py:119–131  ·  view source on GitHub ↗
(name: str)

Source from the content-addressed store, hash-verified

117
118
119def shell_tool_command(name: str) -> str | None:
120 resolved = command_path(name)
121 if resolved:
122 return name
123 module_fallbacks = {
124 "snakemake": "snakemake",
125 "multiqc": "multiqc",
126 "cutadapt": "cutadapt",
127 }
128 module_name = module_fallbacks.get(name)
129 if module_name and module_present(module_name):
130 return f"{sys.executable} -m {module_name}"
131 return None
132
133
134def run_cmd(cmd: list[str], cwd: Path, timeout: int | None = None) -> dict[str, Any]:

Callers

nothing calls this directly

Calls 3

command_pathFunction · 0.70
module_presentFunction · 0.70
getMethod · 0.45

Tested by

no test coverage detected