https://github.com/a5sys/a5sys-coding-standard
https://github.com/a5sys/a5sys-coding-standard
Last synced: 10 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/a5sys/a5sys-coding-standard
- Owner: A5sys
- License: mit
- Created: 2015-11-17T10:53:53.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2018-11-17T10:36:54.000Z (about 7 years ago)
- Last Synced: 2025-01-19T11:43:35.035Z (11 months ago)
- Language: PHP
- Size: 34.2 KB
- Stars: 0
- Watchers: 6
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# A5sys PHP CodeSniffer Coding Standard
## Requirements
**This standard requires phpcs version 3. It does not work with version 2.**
## Installation
### Composer
This standard can be installed with the [Composer](https://getcomposer.org/) dependency manager.
1. [Install Composer](https://getcomposer.org/doc/00-intro.md)
2. Install the coding standard as a dependency of your project
composer require --dev A5sys/A5sys-coding-standard
3. Add the coding standard to the PHP_CodeSniffer install path
vendor/bin/phpcs --config-set installed_paths vendor/A5sys/A5sys-coding-standard
4. Check the installed coding standards for "A5sys"
vendor/bin/phpcs -i
5. Done!
vendor/bin/phpcs /path/to/code
### Stand-alone
1. Install [PHP_CodeSniffer](https://github.com/squizlabs/PHP_CodeSniffer)
2. Checkout this repository
git clone git://github.com/A5sys/A5sys-coding-standard.git
3. Add the coding standard to the PHP_CodeSniffer install path
phpcs --config-set installed_paths /path/to/A5sys-coding-standards
Or copy/symlink this repository's "A5sys"-folder inside the phpcs `Standards` directory
4. Check the installed coding standards for "A5sys"
phpcs -i
5. Done!
phpcs /path/to/code