mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-04-29 03:29:25 -05:00
allow pre-commit run --files ... against unmerged files
This commit is contained in:
@@ -333,7 +333,7 @@ def run(
|
||||
stash = not args.all_files and not args.files
|
||||
|
||||
# Check if we have unresolved merge conflict files and fail fast.
|
||||
if _has_unmerged_paths():
|
||||
if stash and _has_unmerged_paths():
|
||||
logger.error('Unmerged files. Resolve before committing.')
|
||||
return 1
|
||||
if bool(args.from_ref) != bool(args.to_ref):
|
||||
|
||||
Reference in New Issue
Block a user