|
31 | 31 | "phpstan/extension-installer": "^1.4.1",
|
32 | 32 | "phpstan/phpstan": "^1.11.4",
|
33 | 33 | "phpstan/phpstan-phpunit": "^1.4.0",
|
34 |
| - "phpunit/phpunit": "^8.5.38" |
| 34 | + "phpunit/phpunit": "^8.5.38", |
| 35 | + "rector/rector": "^1.1.0" |
35 | 36 | },
|
36 | 37 | "suggest": {
|
37 | 38 | "ext-mbstring": "for parsing UTF-8 CSS"
|
|
70 | 71 | ],
|
71 | 72 | "ci:php:fixer": "\"./.phive/php-cs-fixer\" --config=config/php-cs-fixer.php fix --dry-run -v --show-progress=dots --diff bin src tests",
|
72 | 73 | "ci:php:stan": "phpstan --no-progress --configuration=config/phpstan.neon",
|
| 74 | + "ci:php:rector": "\"./vendor/bin/rector\" --no-progress-bar --dry-run --config=config/rector.php", |
73 | 75 | "ci:static": [
|
74 | 76 | "@ci:php:fixer",
|
| 77 | + "@ci:php:rector", |
75 | 78 | "@ci:php:stan"
|
76 | 79 | ],
|
77 | 80 | "ci:tests": [
|
|
80 | 83 | "ci:tests:sof": "\"./vendor/bin/phpunit\" --stop-on-failure --do-not-cache-result",
|
81 | 84 | "ci:tests:unit": "\"./vendor/bin/phpunit\" --do-not-cache-result",
|
82 | 85 | "fix:php": [
|
83 |
| - "@fix:php:fixer" |
| 86 | + "@fix:php:fixer", |
| 87 | + "@fix:php:rector" |
84 | 88 | ],
|
85 | 89 | "fix:php:fixer": "\"./.phive/php-cs-fixer\" --config=config/php-cs-fixer.php fix bin src tests",
|
| 90 | + "fix:php:rector": "\"./vendor/bin/rector\" --config=config/rector.php", |
86 | 91 | "phpstan:baseline": "phpstan --configuration=config/phpstan.neon --generate-baseline=config/phpstan-baseline.neon"
|
87 | 92 | },
|
88 | 93 | "scripts-descriptions": {
|
89 | 94 | "ci": "Runs all dynamic and static code checks.",
|
90 | 95 | "ci:dynamic": "Runs all dynamic code checks (i.e., currently, the unit tests).",
|
91 | 96 | "ci:php:fixer": "Checks the code style with PHP CS Fixer.",
|
92 | 97 | "ci:php:stan": "Checks the types with PHPStan.",
|
| 98 | + "ci:php:rector": "Checks the code for possible code updates and refactoring.", |
93 | 99 | "ci:static": "Runs all static code analysis checks for the code.",
|
94 | 100 | "ci:tests": "Runs all dynamic tests (i.e., currently, the unit tests).",
|
95 | 101 | "ci:tests:sof": "Runs the unit tests and stops at the first failure.",
|
96 | 102 | "ci:tests:unit": "Runs all unit tests.",
|
97 | 103 | "fix:php": "Autofixes all autofixable issues in the PHP code.",
|
98 | 104 | "fix:php:fixer": "Fixes autofixable issues found by PHP CS Fixer.",
|
| 105 | + "fix:php:rector": "Fixes autofixable issues found by Rector.", |
99 | 106 | "phpstan:baseline": "Updates the PHPStan baseline file to match the code."
|
100 | 107 | }
|
101 | 108 | }
|
0 commit comments