Releases: NexusPHP/cs-config
Nexus CS Config v3.3.4
Minor Changes ⚙️
- Update to phpstan 1.0
- Add ignored tags to
phpdoc_to_comment
rule
Please refer to the CHANGELOG for the detailed list of changes.
Full Changelog: v3.3.3...v3.3.4
Nexus CS Config v3.3.3
Minor Changes ⚙️
- Enable
no_alternative_syntax
rule - Change class attributes separation to
none
except for methods - Remove operator override for braces in Nexus80
- Add support for new fixers added in v3.2.0
- Remove deprecated "tokens: use_trait" option
- Use own custom fixers
- Fix phpstan error on v0.12.99
Please refer to the CHANGELOG for the detailed list of changes.
Full Changelog: v3.3.2...v3.3.3
Nexus CS Config v3.3.2
Fixed 🔧
- Fix missing string substitution when
FixerGenerator::create()
fails
Please refer to the CHANGELOG for the detailed list of changes.
Nexus CS Config v3.3.1
Fixed 🔧
- [SpaceAfterCommentStartFixer] Fixed a case where a comment exactly as
//
is causingUndefined array key 1
error
Please refer to the CHANGELOG for the detailed list of changes.
Nexus CS Config v3.3.0
Added 🔥
- Support for custom fixers is added. This release contains two new fixers,
SpaceAfterCommentStartFixer
andNoCodeSeparatorCommentFixer
- Added
FixerGenerator
to easily register all custom fixers in directory
To use the custom fixers in your ruleset, you just need two (2) steps:
- In the
$options
array, add the keycustomFixers
with the valueFixerGenerator::create('path/to/fixers', 'namespace')
. - In the same array, add the key
customRules
with value of array of desired rules.
For example:
$options = [
'finder' => $finder,
+ 'customFixers' => FixerGenerator::create('src/Fixer', 'Nexus\\CsConfig\\Fixer'),
+ 'customRules' => [
+ \Nexus\CsConfig\Fixer\Comment\SpaceAfterCommentStartFixer::name() => true,
+ \Nexus\CsConfig\Fixer\Comment\NoCodeSeparatorCommentFixer::name() => true,
+ ],
];
Stay tuned for more custom fixers in future releases.
Changed ⚙️
- Bump
friendsofphp/php-cs-fixer
version to v3.1.0 River to use latest fixers
Please refer to the CHANGELOG for the detailed list of changes.
Nexus CS Config v3.2.2
Minor Changes ⚙️
- Add support for
trait_import
inclass_attributes_separation
Please refer to the CHANGELOG for the detailed list of changes.
Nexus CS Config v3.2.1
This is a patch release, with many internal changes. Upgrading to this version is safe UNLESS you are using the internal rulesets for yourself.
Bug Fix 🐛
- Fix for
AbstractRulesetTestCase
when configurable fixer is not yet defined by the ruleset.
Internal Changes 🔧
- Forbid running PHPStan on PHP8.1 (for now)
- Standardize
phpunit.xml.dist
structure. - Remove
include/require
from statements requiring blank line before. - [Nexus80] Enable
void_return
fixer - Limit excluded annotations to
@final
and@no-final
only - [Nexus80] Enable
final_public_method_for_abstract_class
- [Nexus80] Enable
phpdoc_to_param_type
andphpdoc_to_return_type
- Remove
@test
annotations from tests - Disable
php_unit_test_class_requires_covers
. Let PHPUnit do the job instead.
Please refer to the CHANGELOG for the detailed list of changes.
Nexus CS Config v3.2.0
⚠️ POSSIBLE BC BREAK
- Libraries using the
AbstractRulesetTestCase
in testing their rulesets may face build errors since the test case has been refactored to be explicit on the options of fixers if these were configurable. Previously, setting totrue
(to get the default configuration) is enough.
Please refer to the CHANGELOG for the detailed list of changes.
Nexus CS Config v3.1.1
Please refer to the CHANGELOG for the detailed list of changes.
Nexus CS Config v3.1.0
Please refer to the CHANGELOG for the detailed list of changes.