mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 16:24:40 +04:00
Implement a simplified xargs in python
This commit is contained in:
parent
a5b56bd9e3
commit
b7d395410b
13 changed files with 130 additions and 62 deletions
|
|
@ -86,7 +86,7 @@ def _run_single_hook(hook, repo, args, write, skips=frozenset()):
|
|||
sys.stdout.flush()
|
||||
|
||||
diff_before = cmd_output('git', 'diff', retcode=None, encoding=None)
|
||||
retcode, stdout, stderr = repo.run_hook(hook, filenames)
|
||||
retcode, stdout, stderr = repo.run_hook(hook, tuple(filenames))
|
||||
diff_after = cmd_output('git', 'diff', retcode=None, encoding=None)
|
||||
|
||||
file_modifications = diff_before != diff_after
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue