-
Notifications
You must be signed in to change notification settings - Fork 177
/
.php-cs-fixer.dist.php
37 lines (31 loc) · 1.11 KB
/
.php-cs-fixer.dist.php
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
<?php
$finder = PhpCsFixer\Finder::create()
->ignoreVCSIgnored(true)
->in(__DIR__.'/lib')
->in(__DIR__.'/data/bin')
->in(__DIR__.'/test')
->append([__FILE__])
// Exclude PHP classes templates/generators, which are not valid PHP files
->exclude('task/generator/skeleton/')
->exclude('plugins/sfDoctrinePlugin/data/generator/')
->exclude('plugins/sfDoctrinePlugin/test/functional/fixtures/')
// Exclude sub-modules folders
->exclude('plugins/sfDoctrinePlugin/lib/vendor/doctrine')
// Exclude generated files (whole directories)
->exclude('functional/fixtures/cache')
->exclude('functional/fixtures/log')
// Exclude generated files (single files)
->notPath('unit/config/fixtures/sfDefineEnvironmentConfigHandler/prefix_result.php')
->notPath('unit/config/fixtures/sfFilterConfigHandler/result.php')
;
$config = new PhpCsFixer\Config();
$config
->setRules([
'@PhpCsFixer' => true,
'@Symfony' => true,
'array_syntax' => ['syntax' => 'short'],
])
->setCacheFile('.cache/php-cs-fixer.cache')
->setFinder($finder)
;
return $config;