mirror of
https://github.com/pre-commit/pre-commit-hooks.git
synced 2026-04-05 03:26:53 +00:00
Add pyupgrade
This commit is contained in:
parent
a11d9314b2
commit
9cee71b5df
19 changed files with 33 additions and 29 deletions
|
|
@ -9,7 +9,7 @@ from pre_commit_hooks.util import cmd_output
|
|||
|
||||
|
||||
def lower_set(iterable):
|
||||
return set(x.lower() for x in iterable)
|
||||
return {x.lower() for x in iterable}
|
||||
|
||||
|
||||
def find_conflicting_filenames(filenames):
|
||||
|
|
@ -35,7 +35,7 @@ def find_conflicting_filenames(filenames):
|
|||
if x.lower() in conflicts
|
||||
]
|
||||
for filename in sorted(conflicting_files):
|
||||
print('Case-insensitivity conflict found: {0}'.format(filename))
|
||||
print('Case-insensitivity conflict found: {}'.format(filename))
|
||||
retv = 1
|
||||
|
||||
return retv
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue