# Path: pre_commit/hook.py
# class Hook(NamedTuple):
#     src: str
#     prefix: Prefix
#     id: str
#     name: str
#     entry: str
#     language: str
#     alias: str
#     files: str
#     exclude: str
#     types: Sequence[str]
#     types_or: Sequence[str]
#     exclude_types: Sequence[str]
#     additional_dependencies: Sequence[str]
#     args: Sequence[str]
#     always_run: bool
#     fail_fast: bool
#     pass_filenames: bool
#     description: str
#     language_version: str
#     log_file: str
#     minimum_pre_commit_version: str
#     require_serial: bool
#     stages: Sequence[str]
#     verbose: bool
# 
#     @property
#     def cmd(self) -> tuple[str, ...]:
#         return (*shlex.split(self.entry), *self.args)
# 
#     @property
#     def install_key(self) -> tuple[Prefix, str, str, tuple[str, ...]]:
#         return (
#             self.prefix,
#             self.language,
#             self.language_version,
#             tuple(self.additional_dependencies),
#         )
# 
#     @classmethod
#     def create(cls, src: str, prefix: Prefix, dct: dict[str, Any]) -> Hook:
#         # TODO: have cfgv do this (?)
#         extra_keys = set(dct) - _KEYS
#         if extra_keys:
#             logger.warning(
#                 f'Unexpected key(s) present on {src} => {dct["id"]}: '
#                 f'{", ".join(sorted(extra_keys))}',
#             )
#         return cls(src=src, prefix=prefix, **{k: dct[k] for k in _KEYS})
# 
# Path: pre_commit/languages/helpers.py
# FIXED_RANDOM_SEED = 1542676187
# SHIMS_RE = re.compile(r'[/\\]shims[/\\]')
# def exe_exists(exe: str) -> bool:
# def run_setup_cmd(prefix: Prefix, cmd: tuple[str, ...], **kwargs: Any) -> None:
# def environment_dir(d: None, language_version: str) -> None: ...
# def environment_dir(d: str, language_version: str) -> str: ...
# def environment_dir(d: str | None, language_version: str) -> str | None:
# def assert_version_default(binary: str, version: str) -> None:
# def assert_no_additional_deps(
#         lang: str,
#         additional_deps: Sequence[str],
# ) -> None:
# def basic_get_default_version() -> str:
# def basic_healthy(prefix: Prefix, language_version: str) -> bool:
# def no_install(
#         prefix: Prefix,
#         version: str,
#         additional_dependencies: Sequence[str],
# ) -> NoReturn:
# def target_concurrency(hook: Hook) -> int:
# def _shuffled(seq: Sequence[str]) -> list[str]:
# def run_xargs(
#         hook: Hook,
#         cmd: tuple[str, ...],
#         file_args: Sequence[str],
#         **kwargs: Any,
# ) -> tuple[int, bytes]:
# 
# Path: pre_commit/languages/docker.py
# def docker_cmd() -> tuple[str, ...]:  # pragma: win32 no cover
#     return (
#         'docker', 'run',
#         '--rm',
#         *get_docker_user(),
#         # https://docs.docker.com/engine/reference/commandline/run/#mount-volumes-from-container-volumes-from
#         # The `Z` option tells Docker to label the content with a private
#         # unshared label. Only the current container can use a private volume.
#         '-v', f'{_get_docker_path(os.getcwd())}:/src:rw,Z',
#         '--workdir', '/src',
#     )


from typing import Sequence
from pre_commit.hook import Hook
from pre_commit.languages import helpers
from pre_commit.languages.docker import docker_cmd
from __future__ import annotations



ENVIRONMENT_DIR = None
get_default_version = helpers.basic_get_default_version
healthy = helpers.basic_healthy
install_environment = helpers.no_install


def run_hook(

# Path: pre_commit/hook.py
# class Hook(NamedTuple):
#     src: str
#     prefix: Prefix
#     id: str
#     name: str
#     entry: str
#     language: str
#     alias: str
#     files: str
#     exclude: str
#     types: Sequence[str]
#     types_or: Sequence[str]
#     exclude_types: Sequence[str]
#     additional_dependencies: Sequence[str]
#     args: Sequence[str]
#     always_run: bool
#     fail_fast: bool
#     pass_filenames: bool
#     description: str
#     language_version: str
#     log_file: str
#     minimum_pre_commit_version: str
#     require_serial: bool
#     stages: Sequence[str]
#     verbose: bool
# 
#     @property
#     def cmd(self) -> tuple[str, ...]:
#         return (*shlex.split(self.entry), *self.args)
# 
#     @property
#     def install_key(self) -> tuple[Prefix, str, str, tuple[str, ...]]:
#         return (
#             self.prefix,
#             self.language,
#             self.language_version,
#             tuple(self.additional_dependencies),
#         )
# 
#     @classmethod
#     def create(cls, src: str, prefix: Prefix, dct: dict[str, Any]) -> Hook:
#         # TODO: have cfgv do this (?)
#         extra_keys = set(dct) - _KEYS
#         if extra_keys:
#             logger.warning(
#                 f'Unexpected key(s) present on {src} => {dct["id"]}: '
#                 f'{", ".join(sorted(extra_keys))}',
#             )
#         return cls(src=src, prefix=prefix, **{k: dct[k] for k in _KEYS})
# 
# Path: pre_commit/languages/helpers.py
# FIXED_RANDOM_SEED = 1542676187
# SHIMS_RE = re.compile(r'[/\\]shims[/\\]')
# def exe_exists(exe: str) -> bool:
# def run_setup_cmd(prefix: Prefix, cmd: tuple[str, ...], **kwargs: Any) -> None:
# def environment_dir(d: None, language_version: str) -> None: ...
# def environment_dir(d: str, language_version: str) -> str: ...
# def environment_dir(d: str | None, language_version: str) -> str | None:
# def assert_version_default(binary: str, version: str) -> None:
# def assert_no_additional_deps(
#         lang: str,
#         additional_deps: Sequence[str],
# ) -> None:
# def basic_get_default_version() -> str:
# def basic_healthy(prefix: Prefix, language_version: str) -> bool:
# def no_install(
#         prefix: Prefix,
#         version: str,
#         additional_dependencies: Sequence[str],
# ) -> NoReturn:
# def target_concurrency(hook: Hook) -> int:
# def _shuffled(seq: Sequence[str]) -> list[str]:
# def run_xargs(
#         hook: Hook,
#         cmd: tuple[str, ...],
#         file_args: Sequence[str],
#         **kwargs: Any,
# ) -> tuple[int, bytes]:
# 
# Path: pre_commit/languages/docker.py
# def docker_cmd() -> tuple[str, ...]:  # pragma: win32 no cover
#     return (
#         'docker', 'run',
#         '--rm',
#         *get_docker_user(),
#         # https://docs.docker.com/engine/reference/commandline/run/#mount-volumes-from-container-volumes-from
#         # The `Z` option tells Docker to label the content with a private
#         # unshared label. Only the current container can use a private volume.
#         '-v', f'{_get_docker_path(os.getcwd())}:/src:rw,Z',
#         '--workdir', '/src',
#     )


# Path: pre_commit/languages/docker_image.py
from typing import Sequence
from pre_commit.hook import Hook
from pre_commit.languages import helpers
from pre_commit.languages.docker import docker_cmd

from __future__ import annotations



ENVIRONMENT_DIR = None
get_default_version = helpers.basic_get_default_version
healthy = helpers.basic_healthy
install_environment = helpers.no_install


def run_hook(

        hook: Hook,