CakePHP CodeSniffer で Variable "xxx" is not in valid camel caps format って言われたとき

More than 1 year has passed since last update.

CakePHPは2系、CakePHP CodeSnifferは1系。

cd CodeSniffer/Standards
mkdir CakePHP_Custom
vi CakePHP_Custom/ruleset.xml

<?xml version="1.0"?>
<ruleset name="CakePHP_Custom">
 <description>CakePHP coding standard Custom</description>

 <rule ref="CakePHP">
  <exclude name="CakePHP.NamingConventions.ValidVariableName" />

phpcs --standard=CakePHP_Custom target_file.php


Sign up for free and join this conversation.
Sign Up
If you already have a Qiita account log in.