MCPcopy Index your code
hub / github.com/pre-commit/pre-commit / _need_installed

Function _need_installed

pre_commit/repository.py:215–222  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

213
214def install_hook_envs(hooks: Sequence[Hook], store: Store) -> None:
215 def _need_installed() -> list[Hook]:
216 seen: set[tuple[Prefix, str, str, tuple[str, ...]]] = set()
217 ret = []
218 for hook in hooks:
219 if hook.install_key not in seen and not _hook_installed(hook):
220 ret.append(hook)
221 seen.add(hook.install_key)
222 return ret
223
224 if not _need_installed():
225 return

Callers 1

install_hook_envsFunction · 0.85

Calls 1

_hook_installedFunction · 0.85

Tested by

no test coverage detected