karen-nalbandian/symfony-coding-standard
Composer 安装命令:
composer require karen-nalbandian/symfony-coding-standard
包简介
CodeSniffer ruleset for the Symfony coding standard (PCG Cube flavor)
README 文档
README
A coding standard to check against the Symfony coding standards, based on excellent escapestudios/symfony2-coding-standard repository.
Important note: Please be careful using this library, as it is for internal usage, and probably will not be maintained
Differences
The following standards has been modified:
- added the Symfony.Commenting.FunctionComment.MissingParamType
- removed the Symfony.Commenting.FunctionComment.SpacingAfterParamType
- removed the Symfony.Commenting.Annotations.Invalid
- removed the Symfony.Functions.Arguments.Invalid
- removed the Squiz.Strings.ConcatenationSpacing.PaddingFound
Installation
Composer
This standard can be installed with the Composer dependency manager.
-
Install the coding standard as a dependency of your project
composer require --dev karen-nalbandian/symfony-coding-standard:dev-master -
Add the coding standard to the PHP_CodeSniffer install path
vendor/bin/phpcs --config-set installed_paths vendor/karen-nalbandian/symfony-coding-standard -
Check the installed coding standards for "Symfony"
vendor/bin/phpcs -i -
Done!
vendor/bin/phpcs /path/to/code
### Stand-alone
-
Install PHP_CodeSniffer
-
Checkout this repository
git clone https://github.com/karen-nalbandian/symfony-coding-standard.git -
Add the coding standard to the PHP_CodeSniffer install path
phpcs --config-set installed_paths /path/to/symfony-coding-standardOr copy/symlink this repository's "Symfony"-folder inside the phpcs
Standardsdirectory -
Check the installed coding standards for "Symfony"
phpcs -i -
Done!
phpcs /path/to/code
统计信息
- 总下载量: 16
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2018-07-29