mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-04-14 17:41:45 +04:00
When `pre-commit run --files <files>` is called outside a git repository, the tool previously raised a FatalError and exited with code 1. - Print a warning that pre-commit is running outside a git repository and only the explicitly passed files will be checked - Continue execution rather than aborting - All other commands (and `run` without `--files`) retain the existing fatal error behavior This modification helps use pre-commit in jujutsu worktrees as long as the modified file list is supplied on command line. Signed-off-by: Venkateswara Rao Mandela <venkat.mandela@gmail.com> |
||
|---|---|---|
| .. | ||
| commands | ||
| languages | ||
| meta_hooks | ||
| resources | ||
| __init__.py | ||
| __main__.py | ||
| all_languages.py | ||
| clientlib.py | ||
| color.py | ||
| constants.py | ||
| envcontext.py | ||
| error_handler.py | ||
| errors.py | ||
| file_lock.py | ||
| git.py | ||
| hook.py | ||
| lang_base.py | ||
| logging_handler.py | ||
| main.py | ||
| output.py | ||
| parse_shebang.py | ||
| prefix.py | ||
| repository.py | ||
| staged_files_only.py | ||
| store.py | ||
| util.py | ||
| xargs.py | ||
| yaml.py | ||
| yaml_rewrite.py | ||