blob: 308af6c698d8deca6ab9cf9016691f3f6bfae8de (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
|
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
# This Source Code Form is "Incompatible With Secondary Licenses", as
# defined by the Mozilla Public License, v. 2.0.
# This is the Perl::Critic policy file for Bugzilla.
#
# The general rule here is to only add one rule at a time to this file,
# and generally only in situations where we will not generate many false
# positives (requiring spammy # no critic entries) and where we will not
# generate cargo cult behaviour in contributors.
# start with very low requirements, should me moved to 4 soon
severity = 5
# Policies that are currently not implemented in the code
# these should be fixed and removed from here one by one
[-Subroutines::ProhibitExplicitReturnUndef]
[-ValuesAndExpressions::ProhibitLeadingZeros]
[-InputOutput::ProhibitTwoArgOpen]
[-InputOutput::ProhibitBarewordFileHandles]
[Variables::RequireLexicalLoopIterators]
[-BuiltinFunctions::RequireGlobFunction]
[-Variables::ProhibitConditionalDeclarations]
[-Subroutines::ProhibitReturnSort]
[-TestingAndDebugging::ProhibitNoStrict]
# we can deal with this later.
[-Subroutines::ProhibitSubroutinePrototypes]
[-Subroutines::ProhibitNestedSubs]
[-ControlStructures::ProhibitMutatingListFunctions]
[-InputOutput::ProhibitInteractiveTest]
[BuiltinFunctions::ProhibitBooleanGrep]
severity = 5
[InputOutput::RequireEncodingWithUTF8Layer]
severity = 3
######################################################################
# Disabling critic sucks, configure a better policy
[Miscellanea::ProhibitUnrestrictedNoCritic]
severity = 5
[Miscellanea::ProhibitUselessNoCritic]
severity = 5
######################################################################
# Temporarily downgraded as the noise obscures more important tests
[Subroutines::RequireFinalReturn]
severity = 3
[Subroutines::RequireArgUnpacking]
severity = 3
[Subroutines::ProhibitBuiltinHomonyms]
severity = 3
[Modules::ProhibitAutomaticExportation]
severity = 3
######################################################################
# Policies that Bugzilla disagrees with or tolerates as worth the risk
[-BuiltinFunctions::ProhibitStringyEval]
#[-ClassHierarchies::ProhibitExplicitISA]
[-CodeLayout::ProhibitHardTabs]
#[-ControlStructures::ProhibitUnlessBlocks]
#[-Subroutines::ProhibitExplicitReturnUndef]
#[-TestingAndDebugging::ProhibitNoStrict]
#[-TestingAndDebugging::ProhibitNoWarnings]
#[-ValuesAndExpressions::ProhibitConstantPragma]
#[-ValuesAndExpressions::ProhibitMixedBooleanOperators]
#[-Variables::ProhibitPunctuationVars]
|