composer require botble/git-commit-checker
For version <= 5.4:
Add to section providers
of config/app.php
:
// config/app.php
'providers' => [
...
Botble\GitCommitChecker\Providers\GitCommitCheckerServiceProvider::class,
];
Publish configuration:
php artisan vendor:publish --provider="Botble\GitCommitChecker\Providers\GitCommitCheckerServiceProvider" --tag=config
php artisan git:install-hooks
- Run test manually (made sure that you've added all changed files to git stage)
php artisan git:pre-commit