MCPcopy Create free account
hub / github.com/commitizen-tools/commitizen / available_hook_installers

Function available_hook_installers

commitizen/project_info.py:10–17  ·  view source on GitHub ↗

Return hook installer CLIs found on PATH. ``pre-commit`` and ``prek`` are interchangeable. ``pre-commit`` is listed first when both are present so existing setups keep a stable default unless the user is asked to choose.

()

Source from the content-addressed store, hash-verified

8
9
10def available_hook_installers() -> list[str]:
11 """Return hook installer CLIs found on PATH.
12
13 ``pre-commit`` and ``prek`` are interchangeable. ``pre-commit`` is
14 listed first when both are present so existing setups keep a stable
15 default unless the user is asked to choose.
16 """
17 return [tool for tool in _HOOK_INSTALLERS if shutil.which(tool)]
18
19
20def is_pre_commit_installed() -> bool:

Callers 1

is_pre_commit_installedFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected