Setup pre-commit hook in php projects for lint, code standard, test cases etc.
- php >= 5.6
- composer
- git
| /* | |
| Reads a CSV file in chunks of 10 lines at a time | |
| and returns them in an array of objects for processing. | |
| Assumes the first line of the CSV file has headings | |
| that will be used as the object name for the item you are | |
| processing. i.e. the heading is CurrentURL then refer to | |
| $item->CurrentURL |
| git branch | grep -v "master\|develop" | xargs git branch -D |
| <?php | |
| use PhpCsFixer\Config; | |
| use PhpCsFixer\Finder; | |
| $rules = [ | |
| 'array_syntax' => ['syntax' => 'short'], | |
| 'binary_operator_spaces' => [ | |
| 'default' => 'single_space', | |
| 'operators' => ['=>' => null] |