Custom Static Review classes
- Custom Static Review classes
- Table of Contents
- Prerequisites
- Change Log
- Installation
- Example
- Contributing
- Security
- Credits
- About Padosoft
- License
Prerequisites of package are "sjparkinson/static-review": "squizlabs/php_codesniffer": "phpunit/phpunit" "scrutinizer/ocular" "phpmd/phpmd"
installed as required in composer
create a new Hooks directory and copy pre-commit.php into from src/config folder.
$ mkdir hooks
$ copy vendor/padosoft/static-review/src/config/pre-commit.php hooks/pre-commit.php
Please see CHANGELOG for more information what has changed recently.
You can install the package via composer:
$ composer require padosoft/static-review
Open hooks/pre-commit.php in your root folder (created in PREREQUISITES above section) and add custom review. For example if you want to add VarDumpReview and DdReview:
$review->addReview(new LineEndingsReview())
//.....
//.....
//.....
//.....
->addReview(new VarDumpReview());
->addReview(new DdReview());
In the end, create a pre-commit hook, by running the following command:
create in .git/hooks a file named pre-commit like this
****************************************************************
#!/bin/sh
php.exe "hooks/pre-commit.php"
****************************************************************
This for windows environment, for linux and mac you must use this
****************************************************************
#!/bin/sh
php "hooks/pre-commit.php"
****************************************************************
Please see CONTRIBUTING and CONDUCT for details.
If you discover any security related issues, please email instead of using the issue tracker.
Padosoft is a software house based in Florence, Italy. Specialized in E-commerce and web sites.
The MIT License (MIT). Please see License File for more information.