mirror of
https://github.com/CorsixTH/CorsixTH.git
synced 2025-07-23 04:13:01 +02:00
scripts: last space/blank line issues detected by flake8
This commit is contained in:
@@ -15,7 +15,7 @@ import sys
|
||||
|
||||
def is_BOM_encoded_file(path):
|
||||
""" Returns whether |path| is a file that is encoded in UTF-8 with BOM. """
|
||||
if not os.path.isfile(path):
|
||||
if not os.path.isfile(path):
|
||||
return False
|
||||
|
||||
with open(path, 'rb') as f:
|
||||
|
@@ -14,6 +14,7 @@ import sys
|
||||
|
||||
TRAILING_SEQUENCE = re.compile(r'[ \t][\r\n]')
|
||||
|
||||
|
||||
def has_trailing_whitespace(path):
|
||||
""" Returns whether |path| has trailing whitespace. """
|
||||
if os.path.isfile(path):
|
||||
@@ -26,7 +27,6 @@ def has_trailing_whitespace(path):
|
||||
return False
|
||||
|
||||
|
||||
|
||||
if len(sys.argv) > 2:
|
||||
sys.exit('Usage: {} [root]'.format(sys.argv[0]))
|
||||
|
||||
|
Reference in New Issue
Block a user