1 | <?php |
||
2 | |||
3 | namespace drupol\PhpCsFixerConfigsDrupal\Config; |
||
4 | |||
5 | use drupol\PhpCsFixerConfigsDrupal\Fixer\BlankLineBeforeEndOfClass; |
||
6 | use drupol\PhpCsFixerConfigsDrupal\Fixer\ControlStructureCurlyBracketsElseFixer; |
||
7 | use drupol\PhpCsFixerConfigsDrupal\Fixer\InlineCommentSpacerFixer; |
||
8 | use drupol\PhpCsFixerConfigsDrupal\Fixer\TryCatchBlock; |
||
9 | use drupol\PhpCsFixerConfigsDrupal\Fixer\UppercaseConstantsFixer; |
||
0 ignored issues
–
show
|
|||
10 | use drupol\PhpCsFixerConfigsPhp\Config\Php; |
||
11 | use drupol\PhpCsFixerConfigsPhp\Config\YamlConfig; |
||
12 | |||
13 | /** |
||
14 | * Class Drupal. |
||
15 | */ |
||
16 | final class Drupal extends YamlConfig |
||
17 | { |
||
18 | /** |
||
19 | * Drupal constructor. |
||
20 | */ |
||
21 | 2 | public function __construct() |
|
22 | { |
||
23 | 2 | parent::__construct('/drupol/drupal-conventions/drupal'); |
|
24 | |||
25 | 2 | $parent = (new Php()) |
|
26 | 2 | ->withRulesFromYaml(__DIR__ . '/../../config/drupal/phpcsfixer.rules.yml'); |
|
27 | |||
28 | $this |
||
29 | 2 | ->setRules($parent->getRules()); |
|
30 | |||
31 | $this |
||
32 | 2 | ->setIndent(' '); |
|
33 | |||
34 | $this |
||
35 | 2 | ->setLineEnding($parent->getLineEnding()); |
|
36 | |||
37 | $this |
||
38 | 2 | ->registerCustomFixers([ |
|
39 | 2 | new BlankLineBeforeEndOfClass($this->getIndent(), $this->getLineEnding()), |
|
40 | 2 | new ControlStructureCurlyBracketsElseFixer($this->getIndent(), $this->getLineEnding()), |
|
41 | 2 | new InlineCommentSpacerFixer(), |
|
42 | 2 | new TryCatchBlock($this->getIndent(), $this->getLineEnding()), |
|
43 | 2 | // Work in progress |
|
44 | //new NewlineAfterLastCommaInArrayFixer($this->getIndent(), $this->getLineEnding()), |
||
45 | ]); |
||
46 | |||
47 | $this |
||
48 | ->setRiskyAllowed(true); |
||
49 | 2 | ||
50 | $this |
||
51 | ->setFinder( |
||
52 | 2 | $parent->getFinder() |
|
53 | 2 | ->name('*.inc') |
|
54 | 2 | ->name('*.install') |
|
55 | 2 | ->name('*.module') |
|
56 | 2 | ->name('*.profile') |
|
57 | 2 | ->name('*.php') |
|
58 | 2 | ->name('*.theme') |
|
59 | 2 | ->in($_SERVER['PWD']) |
|
60 | 2 | ); |
|
61 | } |
||
62 | } |
||
63 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths