[dak/master 07/23] Add a docstring for parse_lintian_output
Signed-off-by: Chris Lamb <lamby@debian.org>
---
daklib/lintian.py | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/daklib/lintian.py b/daklib/lintian.py
index fbd1bb7..c0ee316 100644
--- a/daklib/lintian.py
+++ b/daklib/lintian.py
@@ -1,6 +1,13 @@
from regexes import re_parse_lintian
def parse_lintian_output(output):
+ """
+ Parses Lintian output and returns a generator with the data.
+
+ >>> list(parse_lintian_output('W: pkgname: some-tag path/to/file'))
+ [('W', 'pkgname', 'some-tag', 'path/to/file')]
+ """
+
for line in output.split('\n'):
m = re_parse_lintian.match(line)
if m:
--
1.6.3.3
Reply to: