[damned-lies] Skip commented lines when reading makefiles



commit 009823c021c0f3d801574884075cb3fed967f108
Author: Claude Paroz <claude 2xlibre net>
Date:   Fri Sep 14 20:47:30 2018 +0200

    Skip commented lines when reading makefiles

 stats/utils.py | 2 ++
 1 file changed, 2 insertions(+)
---
diff --git a/stats/utils.py b/stats/utils.py
index a5d85e23..1b369f60 100644
--- a/stats/utils.py
+++ b/stats/utils.py
@@ -192,6 +192,8 @@ class MakefileWrapper:
         found = None
         for line in self.content.splitlines():
             line = line.strip()
+            if line.startswith('#'):
+                continue
             if non_terminated_content:
                 line = non_terminated_content + " " + line
             # Test if line is non terminated (end with \ or even quote count)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]