summaryrefslogtreecommitdiff
path: root/igor.py
diff options
context:
space:
mode:
Diffstat (limited to 'igor.py')
-rw-r--r--igor.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/igor.py b/igor.py
index e596f873..d0116408 100644
--- a/igor.py
+++ b/igor.py
@@ -64,6 +64,7 @@ def do_check_eol(args):
return
checked.add(fname)
+ line = None
for n, line in enumerate(open(fname, "rb")):
if crlf:
if "\r" in line:
@@ -77,6 +78,9 @@ def do_check_eol(args):
print("%s@%d: trailing whitespace found" % (fname, n+1))
return
+ if line is not None and not line.strip():
+ print("%s: final blank line" % (fname,))
+
def check_files(root, patterns, **kwargs):
for root, dirs, files in os.walk(root):
for f in files: