This repository has been archived by the owner on Nov 19, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathphpcs-ruleset.xml
executable file
·131 lines (109 loc) · 5.72 KB
/
phpcs-ruleset.xml
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
<?xml version="1.0"?>
<!-- PHP_CodeSniffer standard for NextEuropa subsites. -->
<!-- See http://pear.php.net/manual/en/package.php.php-codesniffer.annotated-ruleset.php -->
<ruleset name="NextEuropa">
<description>Drupal coding standard for NextEuropa subsites</description>
<rule ref="./vendor/drupal/coder/coder_sniffer/Drupal" />
<rule ref="./vendor/drupal/coder/coder_sniffer/DrupalPractice" />
<rule ref="./vendor/ec-europa/qa-automation/DrupalSecure" />
<rule ref="./vendor/ec-europa/qa-automation/QualityAssurance" />
<!-- Minified files don't have to comply with coding standards. -->
<exclude-pattern>*\.min\.css</exclude-pattern>
<exclude-pattern>*\.min\.js</exclude-pattern>
<exclude-pattern>*/themes/*/css/style.css</exclude-pattern>
<!-- Exclude node_modules. -->
<exclude-pattern>node_modules*</exclude-pattern>
<!-- Exclude starterkit. -->
<exclude-pattern>dt_STARTERKIT</exclude-pattern>
<!-- Exclude generated and third party code -->
<exclude-pattern>bootstrap-sass</exclude-pattern>
<exclude-pattern>styleguide</exclude-pattern>
<exclude-pattern>js/libraries</exclude-pattern>
<exclude-pattern>*/style-sass*.css</exclude-pattern>
<!-- Exclude settings.php -->
<exclude-pattern>*/settings.php</exclude-pattern>
<!-- Exclude files that do not contain PHP, Javascript or CSS code. -->
<exclude-pattern>*\.json</exclude-pattern>
<exclude-pattern>*\.sh</exclude-pattern>
<exclude-pattern>*\.xml</exclude-pattern>
<exclude-pattern>*\.yml</exclude-pattern>
<exclude-pattern>composer.lock</exclude-pattern>
<!-- Exclude third party code. -->
<exclude-pattern>resources/cloudformation</exclude-pattern>
<exclude-pattern>resources/codedeploy</exclude-pattern>
<exclude-pattern>resources/vendor</exclude-pattern>
<!-- Exclude EntityReference handlers -->
<exclude-pattern>*/behavior/*.class.php</exclude-pattern>
<!-- Exclude non drupal folders. -->
<exclude-pattern>/vendor</exclude-pattern>
<exclude-pattern>/src</exclude-pattern>
<exclude-pattern>/resources</exclude-pattern>
<!-- Exclude folders of example modules. -->
<exclude-pattern>**/example_module</exclude-pattern>
<exclude-pattern>**/myproject_core</exclude-pattern>
<exclude-pattern>**/example_theme</exclude-pattern>
<!-- Views handlers not strictly follow Drupal class name conventions. -->
<rule ref="Drupal.NamingConventions.ValidClassName">
<exclude-pattern>modules/**/views/*.inc</exclude-pattern>
<exclude-pattern>modules/**/views*.inc</exclude-pattern>
<exclude-pattern>cwt_team_handler_field_node_source_language_path.inc</exclude-pattern>
<exclude-pattern>context_condition_node_taxonomy_uuid.inc</exclude-pattern>
</rule>
<!-- Views handlers not strictly follow Drupal function name conventions. -->
<rule ref="Drupal.NamingConventions.ValidFunctionName">
<exclude-pattern>modules/**/views/*.inc</exclude-pattern>
<exclude-pattern>modules/**/views*.inc</exclude-pattern>
<exclude-pattern>context_condition_node_taxonomy_uuid.inc</exclude-pattern>
</rule>
<!-- Phing tasks require to use CamelCaps for argument names. -->
<rule ref="Drupal.NamingConventions.ValidVariableName">
<exclude-pattern>src/Phing</exclude-pattern>
</rule>
<!-- Features creates violations for fields. -->
<rule ref="Drupal.Commenting.InlineComment.InvalidEndChar">
<exclude-pattern>*.features.field.inc</exclude-pattern>
<exclude-pattern>*.features.field_*.inc</exclude-pattern>
<exclude-pattern>*.features.wysiwyg.inc</exclude-pattern>
</rule>
<!-- Features creates violations for fields. -->
<rule ref="Drupal.Files.LineLength">
<exclude-pattern>*.features.field.inc</exclude-pattern>
<exclude-pattern>*.features.field_*.inc</exclude-pattern>
<exclude-pattern>*.features.menu_links.inc</exclude-pattern>
<exclude-pattern>modules/**/views/*.inc</exclude-pattern>
</rule>
<!-- FieldGroup titles are not translatable. -->
<rule ref="Drupal.Semantics.FunctionT.NotLiteralString">
<exclude-pattern>*/nexteuropa_inpage_nav.module</exclude-pattern>
</rule>
<!-- Exported translations. -->
<rule ref="Drupal.Semantics.FunctionT.BackslashSingleQuote">
<exclude-pattern>*.features.*.inc</exclude-pattern>
</rule>
<!-- Exclude tr. -->
<rule ref="Drupal.Semantics.FunctionT.ConcatString">
<exclude-pattern>*.*</exclude-pattern>
</rule>
<!-- Wysiwyg profiles exported in Features do not have a trailing period. -->
<!-- Remove this once https://www.drupal.org/node/2724173 is in. -->
<rule ref="Drupal.Commenting.InlineComment.InvalidEndChar">
<exclude-pattern>*.features.wysiwyg.inc</exclude-pattern>
</rule>
<!-- Disallow short array -->
<rule ref="Generic.Arrays.DisallowLongArraySyntax">
<severity>0</severity>
<!-- Exclude features generated files from this rule -->
<exclude-pattern>*.ds.*.inc</exclude-pattern>
<exclude-pattern>*.default_*.inc</exclude-pattern>
<exclude-pattern>*.file_default_displays.*.inc</exclude-pattern>
<exclude-pattern>*.views_default.*.inc</exclude-pattern>
<exclude-pattern>*.facetapi_defaults.*.inc</exclude-pattern>
<exclude-pattern>*.custom_formatters.*.inc</exclude-pattern>
<exclude-pattern>*.context.*.inc</exclude-pattern>
<exclude-pattern>*.strongarm.*.inc</exclude-pattern>
<exclude-pattern>*.variable.*.inc</exclude-pattern>
<exclude-pattern>*.features.*.inc</exclude-pattern>
<exclude-pattern>*.field_group.inc</exclude-pattern>
<exclude-pattern>src/Phing</exclude-pattern>
</rule>
</ruleset>