Give readers a heads up that the tab width needs to be explicitly changed in the package settings and that certain config options may present problems.
Version 0.4.0 of the DealerDirect Composer plugin registers each standard individually as if they were root-directory standards, not a collection of standards which exposes a bug in PHPCS 3.x.
Refs:
* squizlabs/PHP_CodeSniffer/pull/1581
* DealerDirect/phpcodesniffer-composer-installer/issues/33
Travis:
* No longer test the build against PHP 5.2.
* Only test against PHP 5.3 icw PHPCS 2.x.
* Test all other PHP versions against both PHPCS 2.x as well as `master` (3.x).
* Test the build against PHPCS 3.x using the `master` branch.
* Removed allowance for build failures against `master`.
* Adjusted phpunit command to allow for testing on both PHPCS 2.x as well as 3.x.
Composer:
* Add the minimum required PHP version.
* Make the PHPCS requirement more specific and allow for PHPCS 3.x.
"Own" PHPCS custom ruleset:
* Enforce PSR1 namespaces.
Readme:
* Adjusted (minimum) requirements information.
* Updated installation instructions.
* Updated travis example code.
Contributing
* Updated unit test instructions.
* Updated example sniff code.
* Removed reference to potentially upstreaming WPCS to PHPCS as reason for using the PHPCS unit test suite. Let's be fair: the sniffs ought to be unit tested anyway, no matter what.
* Update unit testing conventions example. The example was referring to a now deprecated sniff, so selected another sniff for the example code.
PHPCS 2.9.0 contains a new `PHP_CodeSniffer_Tokens::$textStringTokens` array as well as several other improvements to some of the predefined arrays in `PHP_CodeSniffer_Tokens` which are being used by WPCS.
It therefore makes sense to take advantage of these upstream improvements to automatically improve the results of our sniffing.
In two places, replacing an existing manually created array with the new `PHP_CodeSniffer_Tokens::$textStringTokens` array means that the `T_INLINE_HTML` token is added to the array.
For both instances, the code has been reviewed and it was determined that the `T_INLINE_HTML` token can never be encountered there anyway as both examine function calls, so this should not cause any issues.
Includes some extra unit tests.
Note: in some unit tests the `??=` syntax is being used. This is a new syntax which is expected to be introduced in PHP 7.2.
The RFC for this has been approved, though the actual change has not been merged yet into PHP itself. All the same, PHPCS already accounts for it, so we may as well test that it does so correctly.
* Add a table of contents to the readme which has become quite long.
Auto-generated with: http://ecotrust-canada.github.io/markdown-toc/ and then manually tweaked a little
* Add extra header and indent subheader for rulesets section
* Move the rulesets section up, as it was - by now - quite far down what with all the information on the different integrations
* Update the sniff output example (run against core, extra and docs, not vip)
* Added section about PHPCompatibility sniffs
* Added reference to the wiki
Rewrote "Standards subsets" section in readme:
- added new `WordPress-Docs` subset
- made list nesting reflect actual nesting structure
- reworded for shorter and more uniform descriptions