Bug 1654795 - Fix mach clang-format python3 error. r=andi

Differential Revision: https://phabricator.services.mozilla.com/D84691
This commit is contained in:
Emilio Cobos Álvarez 2020-07-23 14:06:14 +00:00
parent da9ed0a51f
commit a8f027f4ff

View File

@ -2088,7 +2088,7 @@ class StaticAnalysis(MachCommandBase):
# https://git-scm.com/docs/gitglossary#gitglossary-aiddefpathspecapathspec
with open(self._format_ignore_file, 'rb') as exclude_pattern_file:
for pattern in exclude_pattern_file.readlines():
pattern = pattern.rstrip()
pattern = six.ensure_str(pattern.rstrip())
pattern = pattern.replace('.*', '**')
if not pattern or pattern.startswith('#'):
continue # empty or comment