1 |
commit: 81d6536d096154ce0d1ffd0e02849d35a2610578 |
2 |
Author: Arfrever Frehtes Taifersar Arahesis <Arfrever <AT> Apache <DOT> Org> |
3 |
AuthorDate: Thu Nov 22 21:48:57 2012 +0000 |
4 |
Commit: Arfrever Frehtes Taifersar Arahesis <arfrever.fta <AT> gmail <DOT> com> |
5 |
CommitDate: Thu Nov 22 21:48:57 2012 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=81d6536d |
7 |
|
8 |
Automatically generate list of repoman checks. |
9 |
This also reenables InheritDeprecated check, which has been disabled in |
10 |
commit 597826a1cabf654f9b3fff88425d04303e921577. |
11 |
|
12 |
--- |
13 |
pym/repoman/checks.py | 16 +++------------- |
14 |
1 files changed, 3 insertions(+), 13 deletions(-) |
15 |
|
16 |
diff --git a/pym/repoman/checks.py b/pym/repoman/checks.py |
17 |
index 8b80214..fe9330c 100644 |
18 |
--- a/pym/repoman/checks.py |
19 |
+++ b/pym/repoman/checks.py |
20 |
@@ -798,19 +798,9 @@ class PortageInternalVariableAssignment(LineCheck): |
21 |
e = 'Assignment to variable %s' % match.group(2) |
22 |
e += ' on line: %d' |
23 |
return e |
24 |
- |
25 |
-_constant_checks = tuple(chain((c() for c in ( |
26 |
- EbuildHeader, EbuildWhitespace, EbuildBlankLine, EbuildQuote, |
27 |
- EbuildAssignment, Eapi3EbuildAssignment, EbuildUselessDodoc, |
28 |
- EbuildUselessCdS, EbuildNestedDie, |
29 |
- EbuildPatches, EbuildQuotedA, EapiDefinition, |
30 |
- ImplicitRuntimeDeps, |
31 |
- EMakeParallelDisabled, EMakeParallelDisabledViaMAKEOPTS, NoAsNeeded, |
32 |
- DeprecatedBindnowFlags, SrcUnpackPatches, WantAutoDefaultValue, |
33 |
- SrcCompileEconf, Eapi3DeprecatedFuncs, NoOffsetWithHelpers, |
34 |
- Eapi4IncompatibleFuncs, Eapi4GoneVars, BuiltWithUse, |
35 |
- PreserveOldLib, SandboxAddpredict, PortageInternal, |
36 |
- PortageInternalVariableAssignment, DeprecatedUseq, DeprecatedHasq)), |
37 |
+_base_check_classes = (InheritEclass, LineCheck, PhaseCheck) |
38 |
+_constant_checks = tuple(chain((v() for k, v in globals().items() |
39 |
+ if isinstance(v, type) and issubclass(v, LineCheck) and v not in _base_check_classes), |
40 |
(InheritEclass(k, **kwargs) for k, kwargs in _eclass_info.items()))) |
41 |
|
42 |
_here_doc_re = re.compile(r'.*\s<<[-]?(\w+)$') |