summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHeather <Heather@cynede.net>2013-02-11 11:41:04 +0400
committerZac Medico <zmedico@gentoo.org>2013-02-11 01:49:46 -0800
commitde51993645f9656dfa8a74f6bf9cc85ed56ee8fa (patch)
treefc5f038c29a95f7e1ba25baec16ae6cd3d2c2b70
parentebuild: add _reset_legacy_globals for reload (diff)
downloadportage-de51993645f9656dfa8a74f6bf9cc85ed56ee8fa.tar.gz
portage-de51993645f9656dfa8a74f6bf9cc85ed56ee8fa.tar.bz2
portage-de51993645f9656dfa8a74f6bf9cc85ed56ee8fa.zip
nowarn syntax for repoman to ignore
-rw-r--r--pym/repoman/checks.py23
1 files changed, 12 insertions, 11 deletions
diff --git a/pym/repoman/checks.py b/pym/repoman/checks.py
index 9dd3b959d..3b2b124ba 100644
--- a/pym/repoman/checks.py
+++ b/pym/repoman/checks.py
@@ -883,17 +883,18 @@ def run_checks(contents, pkg):
multiline = line
continue
- # Finally we have a full line to parse.
- is_comment = _ignore_comment_re.match(line) is not None
- for lc in checks:
- if is_comment and lc.ignore_comment:
- continue
- if lc.check_eapi(pkg.eapi):
- ignore = lc.ignore_line
- if not ignore or not ignore.match(line):
- e = lc.check(num, line)
- if e:
- yield lc.repoman_check_name, e % (num + 1)
+ if not line.endswith("#nowarn\n"):
+ # Finally we have a full line to parse.
+ is_comment = _ignore_comment_re.match(line) is not None
+ for lc in checks:
+ if is_comment and lc.ignore_comment:
+ continue
+ if lc.check_eapi(pkg.eapi):
+ ignore = lc.ignore_line
+ if not ignore or not ignore.match(line):
+ e = lc.check(num, line)
+ if e:
+ yield lc.repoman_check_name, e % (num + 1)
for lc in checks:
i = lc.end()