anatolygerasimov / code
description
Installs: 1 313
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 1
Forks: 1
Open Issues: 0
Requires
- ext-dom: *
- ext-simplexml: *
- friendsofphp/php-cs-fixer: ^3.2.1
- rector/rector: ^0.12.2 <0.12.21
- vimeo/psalm: ^4.12.0
README
Usage
$ composer require anatolygerasimov/code --dev
$ composer require psalm/plugin-laravel
- add folder configuration for
composer.json
"extra": { "code": { "rector": { "paths": [ "/app/Containers/AppSection" ], "skip": [ "/app/Ship/Migrations/*", "/app/Ship/Core/*", "/app/Containers/*/Data/Migrations/*", "/app/Containers/*/Data/Criterias/*", "/app/Containers/*/Routes/*" ] }, "cs-fixer": { "paths": [ "/app/Containers", "/config", "/database" ], "skip": [ "/bootstrap", "/resources", "/node_modules", "/public", "/storage", "/vendor" ] }, "psalm": { "paths": [ "/app/Containers" ], "skip": [ "/vendor" ], "config": { "plugins": { "pluginClass": [ {"class": "Psalm\\LaravelPlugin\\Plugin"} ] } } } } }
composer.json
"scripts": { "rector": [ "./vendor/bin/rector process --config=./vendor/anatolygerasimov/code/configs/rector.php --clear-cache" ], "rector-check": [ "./vendor/bin/rector process --config=./vendor/anatolygerasimov/code/configs/rector.php --clear-cache --dry-run" ], "php-cs-fixer": [ "./vendor/bin/php-cs-fixer fix --config=./vendor/anatolygerasimov/code/configs/.php_cs.dist.php --allow-risky=yes --using-cache=no" ], "php-cs-fixer-check": [ "./vendor/bin/php-cs-fixer fix --dry-run --config=./vendor/anatolygerasimov/code/configs/.php_cs.dist.php --diff -vv --allow-risky=yes --using-cache=no" ], "psalm": [ "php ./vendor/anatolygerasimov/code/src/psalm_config.php --target=./psalm.xml", "./vendor/bin/psalm --threads=4 --no-cache --config=./psalm.xml", "rm ./psalm.xml" ] }
TODO:
- runner for this tools