hoangphi / pre-commit
Check coding standard & code syntax before commit.
v1.0.2
2023-06-12 04:48 UTC
Requires
- php: ^7.1.3|^8.0|^8.1|^8.2
- laravel/framework: ^5.6|^6|^7|^8|^9|^10
- php-parallel-lint/php-parallel-lint: ^1.0
- squizlabs/php_codesniffer: ^3.3
Requires (Dev)
- phpunit/phpunit: ^6.1|^7.0|^8.0|^9.0
This package is auto-updated.
Last update: 2024-11-12 08:01:58 UTC
README
Installation
composer require hoangphi/pre-commit
Publish the configuration:
php artisan vendor:publish --provider="HoangPhi\PreCommit\Providers\PreCommitServiceProvider" --tag=config
Config pre-commit hooks
php artisan pre-commit:install
- Create PSR default config
phpcs.xml
in your root project.
php artisan pre-commit:create-phpcs
- Added all changed files to git stage and run test manually.
php artisan pre-commit:check