Skip to content

Releases: PHP-CS-Fixer/PHP-CS-Fixer

v3.52.1 15 Keys

19 Mar 21:02
v3.52.1
6e77207
Compare
Choose a tag to compare

What's Changed

  • fix: PhpCsFixer\Tokenizer\Tokens::setSize return type by @kubawerlos in #7900
  • fix: StatementIndentationFixer - do not crash on ternary operator in class property by @kubawerlos in #7899

Full Changelog: v3.52.0...v3.52.1

v3.52.0 15 Keys

18 Mar 18:40
v3.52.0
a3564bd
Compare
Choose a tag to compare

What's Changed

New Contributors

Full Changelog: v3.51.0...v3.52.0

v3.51.0 Insomnia

28 Feb 19:54
v3.51.0
127fa74
Compare
Choose a tag to compare

What's Changed

Full Changelog: v3.50.0...v3.51.0

v3.50.0 Insomnia

23 Feb 23:19
v3.50.0
dbea11d
Compare
Choose a tag to compare

What's Changed

  • feat: Ability to remove unused imports from multi-use statements by @Wirone in #7815
  • feat: Support shortening symbols from multi-use statements (only classes for now) by @Wirone in #7816
  • feat: allow PHPUnit 11 by @kubawerlos in #7824
  • feat: MbStrFunctionsFixer - add support for mb_trim, mb_ltrim and mb_rtrim functions by @kubawerlos in #7840
  • feat: no_superfluous_phpdoc_tags - introduce allow_hidden_params option by @keradus in #7743
  • feat: NoEmptyPhpdocFixer - do not leave empty line after removing PHPDoc by @kubawerlos in #7820
  • feat: introduce PhpdocArrayTypeFixer by @kubawerlos in #7812
  • feat: PhpUnitTestCaseStaticMethodCallsFixer - cover PHPUnit v11 methods by @kubawerlos in #7822
  • feat: Support for multi-use statements in NamespaceUsesAnalyzer by @Wirone in #7814
  • fix: ExecutorWithoutErrorHandler - remove invalid PHP 7.4 type by @kubawerlos in #7845
  • fix: fully_qualified_strict_types must honor template/local type identifiers by @mvorisek in #7724
  • fix: MethodArgumentSpaceFixer - do not break heredoc/nowdoc by @kubawerlos in #7828
  • fix: NumericLiteralSeparatorFixer - do not change float to int when there is nothing after the dot by @kubawerlos in #7805
  • fix: PhpUnitStrictFixer - do not crash on property having the name of method to fix by @kubawerlos in #7804
  • fix: SingleSpaceAroundConstructFixer - correctly recognise multiple constants by @kubawerlos and @Wirone in #7700
  • fix: TypeExpression - handle array shape key with dash by @kubawerlos in #7841
  • fix: do not use wrongly named arguments in data providers by @kubawerlos in #7823
  • fix: Ensure PCNTL extension is always installed in Docker by @Wirone in #7782
  • fix: PhpdocListTypeFixer - support key types containing <…> by @gharlan in #7817
  • fix: Proper build target for local Docker Compose by @Wirone in #7834
  • fix: union PHPDoc support in fully_qualified_strict_types fixer by @mvorisek in #7719
  • chore: add missing types by @kubawerlos in #7842
  • chore: BlocksAnalyzer - raise exception on invalid index by @keradus in #7819
  • chore: DataProviderAnalysis - expect list over array by @keradus in #7800
  • chore: do not use @large on method level by @kubawerlos in #7832
  • chore: do not use @medium on method level by @kubawerlos in #7833
  • chore: Fix typos by @tamiroh in #7835
  • chore: rename variables by @kubawerlos in #7847
  • chore: some improvements around array typehints by @keradus in #7799
  • CI: fix PHP 8.4 job by @kubawerlos in #7829
  • DX: Include symfony/var-dumper in dev tools by @Wirone in #7795

New Contributors

Full Changelog: v3.49.0...v3.50.0

v3.49.0 Insomnia

02 Feb 00:41
v3.49.0
8742f7a
Compare
Choose a tag to compare

What's Changed

  • feat: introduce string_implicit_backslashes as escape_implicit_backslashes replacement by @mvorisek in #7669
  • feat: introduce PhpdocListTypeFixer by @kubawerlos in #7796
  • feat: Add ordered_types to @Symfony by @VincentLanglet in #7356
  • feat: update Symfony.nullable_type_declaration_for_default_null_value config by @keradus in #7773
  • feat: @PhpCsFixer ruleset - enable php_unit_data_provider_static by @mvorisek in #7685
  • fix: ClassKeywordFixer must run before FullyQualifiedStrictTypesFixer by @krzysztofrewak in #7767
  • fix: LowercaseStaticReferenceFixer - do not change typed constants by @kubawerlos in #7775
  • fix: TypeExpression - do not break type using walkTypes method by @kubawerlos in #7785
  • fix: ClassDefinitionFixer for anonymous class with PHPDoc/attribute on separate line by @mvorisek in #7546
  • fix: function_to_constant get_class() replacement by @mvorisek in #7770
  • fix: Allow using cache when running in Docker distribution by @Wirone in #7769
  • fix: PhpdocTypesFixer - handle more complex types by @kubawerlos in #7791
  • docs: Docker - use gitlab reporter in GitLab integration example by @keradus in #7764
  • docs: Docker in CI - don't suggest command that overrides path from config file by @keradus in #7763
  • DX: check deprecations exactly by @keradus in #7742
  • chore: DescribeCommand - better handling of deprecations by @kubawerlos in #7778
  • chore: Exclude topic/core issues/PRs from Stale Bot by @Wirone in #7788
  • chore: add missing key types in PHPDoc types by @kubawerlos in #7779
  • chore(checkbashisms): update to 2.23.7 by @kubawerlos in #7780

Full Changelog: v3.48.0...v3.49.0

v3.48.0 Small Changes

19 Jan 21:44
v3.48.0
a92472c
Compare
Choose a tag to compare

What's Changed

  • feat: PhpdocTypesOrderFixer Support DNF types by @smnandre in #7732
  • fix: work correctly for a switch/case with ternary operator by @kubawerlos in #7756
  • fix: NoUselessConcatOperatorFixer - do not remove new line by @kubawerlos in #7759
  • fix: Support shebang in fixers operating on PHP opening tag by @mvorisek in #7687
  • docs: Add PHP-CS-Fixer integration in a GitHub Action step by @Arkanii in #7757
  • chore: FullyQualifiedStrictTypesFixer must run before OrderedInterfacesFixer by @kubawerlos in #7762

New Contributors

Full Changelog: v3.47.1...v3.48.0

v3.47.1 Big Changes

16 Jan 18:54
v3.47.1
173c60d
Compare
Choose a tag to compare

What's Changed

  • fix: Proper Docker image name suffix by @Wirone in #7739
  • fix: FullyQualifiedStrictTypesFixer - do not modify statements with property fetch and :: by @kubawerlos in #7749
  • fix: FullyQualifiedStrictTypesFixer - do not change case of the symbol when there's name collision between imported class and imported function by @kubawerlos in #7750
  • fix: make BinaryOperatorSpacesFixer work as pre-v3.47 by @Wirone in #7751
  • fix: Do not override short name with relative (longer) reference by @Wirone in #7752

Full Changelog: v3.47.0...v3.47.1

v3.47.0 Big Changes

15 Jan 15:36
v3.47.0
184dd99
Compare
Choose a tag to compare

What's Changed

  • refactor: increase performance by ~7% thanks to Tokens::block*Cache hit increased by ~12% by @keradus in #6176
  • refactor: Tokens - fast check for non-block in 'detectBlockType', evaluate definitions only once in 'getBlockEdgeDefinitions' by @keradus in #7655
  • refactor: Tokens::clearEmptyTokens - play defensive with cache clearing by @keradus in #7658
  • feat: Add support for official Docker images of Fixer by @hgiesenow and @Wirone in #7555
  • feat: Introduce heredoc_closing_marker fixer by @mvorisek in #7660
  • feat: Introduce multiline_string_to_heredoc fixer by @mvorisek in #7665
  • feat: Introduce numeric_literal_separator fixer by @muuvmuuv and @Wirone in #6761
  • feat: Add spacing option to PhpdocAlignFixer by @kusab85 in #6505
  • feat: Add union_types option to phpdoc_to_param_type, phpdoc_to_property_type, and phpdoc_to_return_type fixers by @localheinz in #7672
  • feat: Support typed properties and attributes in fully_qualified_strict_types by @mvorisek in #7659
  • feat: @PhpCsFixer ruleset - enable no_whitespace_before_comma_in_array.after_heredoc by @mvorisek in #7670
  • feat: no_superfluous_phpdoc_tags - support for arrow function by @keradus in #7666
  • feat: Simplify closing marker when possible in heredoc_closing_marker fixer by @mvorisek in #7676
  • fix: Several improvements for fully_qualified_strict_types (respect declared symbols, relative imports, leading backslash in global namespace) by @mvorisek in #7679
  • fix: fully_qualified_strict_types with leading_backslash_in_global_namespace enabled - handle reserved types in phpDoc by @mvorisek in #7648
  • fix: BinaryOperatorSpacesFixer - align correctly when multiple shifts occurs in single line by @wadakatu in #7593
  • fix: ClassReferenceNameCasingFixer capitalizes the property name after the nullsafe operator by @erickskrauch in #7696
  • fix: no_superfluous_phpdoc_tags must honor multiline docs by @mvorisek in #7697
  • fix: NoSpaceAroundDoubleColonFixer must run before MethodChainingIndentationFixer by @mho22 in #7723
  • fix: numeric_literal_separator - Handle zero-leading floats properly by @muuvmuuv in #7737
  • fix: Improve progress bar visual layer by @Slamdunk in #7708
  • fix: indentation of control structure body without braces by @julienfalque in #7663
  • fix: make sure all PHP extensions required by PHPUnit are installed by @kubawerlos in #7727
  • fix: PhpdocToReturnTypeFixerTest - support for arrow functions by @keradus in #7645
  • fix: SimplifiedNullReturnFixer - support array return typehint by @keradus in #7728
  • fix: Support numeric values without leading zero in numeric_literal_separator by @muuvmuuv in #7735
  • chore: better identify EXPERIMENTAL rules by @keradus in #7729
  • chore: fix issue detected by unlocked PHPStan + upgrade dev-tools by @keradus in #7678
  • chore: handle extract() by @keradus in #7684
  • chore: Mention contributors in app info by @mvorisek in #7668
  • chore: no need to mark private methods as internal by @keradus in #7715
  • chore: ProjectCodeTests - dry for function usage extractions by @keradus in #7690
  • chore: reduce PHPStan baseline by @keradus in #7644
  • chore: use numeric literal separator for PHP version IDs by @keradus in #7712
  • chore: use numeric_literal_separator for project by @keradus in #7713
  • chore: Utils::sortElements - better typing by @keradus in #7646
  • CI: Allow running Stale Bot on demand by @Wirone in #7711
  • CI: Fix PHP 8.4 by @mvorisek and @Wirone in #7702
  • CI: Give write permissions to Stale Bot by @Wirone in #7716
  • CI: Use actions/stale v9 by @Wirone in #7710
  • docs: Add information about allowing maintainers to update PRs by @Wirone in #7683
  • docs: CONTRIBUTING.md - update Opening a PR by @keradus in #7691
  • docs: Display/include tool info/version by default in commands and reports by @keradus in #7733
  • DX: NumericLiteralSeparatorFixer - change default strategy to use_separator by @keradus in #7730
  • DX: fix deprecation tests warnings for PHP 7.4 by @mvorisek in #7725
  • DX: update host.docker.internal in Compose override template by @julienfalque in #7661
  • test: ensure we do not forget to run any test related to short_open_tag by @keradus in #7638

New Contributors

Full Changelog: v3.46.0...v3.47.0

v3.46.0 Three Keys

03 Jan 21:38
v3.46.0
be6831c
Compare
Choose a tag to compare

What's Changed

  • chore: reduce PHPStan baseline by @keradus in #7643
  • fix: PHP_CS_FIXER_FUTURE_MODE - proper boolean validation by @keradus in #7651
  • feat: change default ruleset to @PER-CS (only behind PHP_CS_FIXER_FUTURE_MODE=1) by @keradus in #7650
  • fix: PhpdocToParamTypeFixerTest - support for arrow functions by @keradus in #7647
  • feat: Support new/instanceof/use trait in fully_qualified_strict_types by @mvorisek in #7653
  • chore: fix internal typehints in Tokens by @keradus in #7656
  • docs: Show class with unit tests by @mvorisek in #7667
  • fix: Handle FQCN properly with leading_backslash_in_global_namespace option enabled by @mvorisek in #7654
  • fix: FQCN parse phpdoc using full grammar regex by @mvorisek in #7649

Full Changelog: v3.45.0...v3.46.0

v3.45.0 Three Keys

30 Dec 02:07
v3.45.0
c0daa33
Compare
Choose a tag to compare

What's Changed

  • feat: Enable symbol importing in @PhpCsFixer ruleset by @Wirone in #7629
  • test: run tests with "short_open_tag" enabled by @keradus in #7637
  • fix: NoUnneededBracesFixer - improve handling of global namespace by @keradus in #7639

Full Changelog: v3.44.0...v3.45.0