Skip to content

Commit 0686c24

Browse files
committed
Set up rector
Signed-off-by: Philipp Daun <post@philippdaun.net>
1 parent 5e901b1 commit 0686c24

File tree

3 files changed

+159
-0
lines changed

3 files changed

+159
-0
lines changed

composer.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"require-dev": {
3+
"rector/rector": "^2.0"
4+
}
5+
}

composer.lock

Lines changed: 136 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rector.php

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
use Rector\Config\RectorConfig;
6+
7+
return RectorConfig::configure()
8+
->withPaths([__DIR__])
9+
->withSkip([__DIR__ . '/vendor'])
10+
->withPhpSets(php83: true)
11+
->withRules([
12+
// TypedPropertyFromStrictConstructorRector::class
13+
])
14+
// here we can define, what prepared sets of rules will be applied
15+
->withPreparedSets(
16+
// deadCode: true,
17+
// codeQuality: true
18+
);

0 commit comments

Comments
 (0)