mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 08:14:42 +04:00
Implement concurrent execution of individual hooks
This commit is contained in:
parent
1f1cd2bc39
commit
ba5e27e4ec
15 changed files with 104 additions and 14 deletions
|
|
@ -13,4 +13,8 @@ install_environment = helpers.no_install
|
|||
def run_hook(prefix, hook, file_args):
|
||||
cmd = helpers.to_cmd(hook)
|
||||
cmd = (prefix.path(cmd[0]),) + cmd[1:]
|
||||
return xargs(cmd, file_args)
|
||||
return xargs(
|
||||
cmd,
|
||||
file_args,
|
||||
target_concurrency=helpers.target_concurrency(hook),
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue