ricorocks-digital-agency/ricorocks-coding-standard

A set of rules that can be applied to projects to ensure a consistent level of code quality.

v1.1.1 2021-08-20 14:02 UTC

This package is auto-updated.

Last update: 2024-04-20 19:36:01 UTC


README

This project contains sniffers for coding standards that are expected to be met on Ricorocks projects.

Installation

composer require --dev ricorocks-digital-agency/ricorocks-coding-standard

Usage

To use this package, you'll need to have PHP Code Sniffer installed in you project:

composer require --dev squizlabs/php_codesniffer

Now run the code sniffer, pointing the Code Sniffer command to our installed coding standard:

./vendor/bin/phpcs --standard=./vendor/ricorocks-digital-agency/ricorocks-coding-standard/RicorocksStandard ./src

Note: When working in a Laravel project, you should change ./src for ./app ./config ./database ./routes. It usually makes more sense to alias this command to a composer script.