Skip to content

Commit

Permalink
Merge pull request #974 from ergebnis/feature/multiline-comment-openi…
Browse files Browse the repository at this point in the history
…ng-closing-alone

Enhancement: Enable `PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone` fixer
  • Loading branch information
localheinz committed Jan 4, 2024
2 parents a3a83e7 + fc59191 commit 7a9143a
Show file tree
Hide file tree
Showing 27 changed files with 57 additions and 0 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Expand Up @@ -8,6 +8,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

For a full diff see [`6.18.0...main`][6.18.0...main].

### Changed

- Enabled the `PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone` fixer ([#974]), by [@localheinz]

## [`6.18.0`][6.18.0]

For a full diff see [`6.17.0...6.18.0`][6.17.0...6.18.0].
Expand Down Expand Up @@ -1479,6 +1483,7 @@ For a full diff see [`d899e77...1.0.0`][d899e77...1.0.0].
[#971]: https://github.com/ergebnis/php-cs-fixer-config/pull/971
[#972]: https://github.com/ergebnis/php-cs-fixer-config/pull/972
[#973]: https://github.com/ergebnis/php-cs-fixer-config/pull/973
[#974]: https://github.com/ergebnis/php-cs-fixer-config/pull/974

[@dependabot]: https://github.com/apps/dependabot
[@linuxjuggler]: https://github.com/linuxjuggler
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php53.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php54.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php55.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php56.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php70.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php71.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php72.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php73.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php74.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php80.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php81.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php82.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions src/RuleSet/Php83.php
Expand Up @@ -33,6 +33,7 @@ public static function create(): RuleSet

return RuleSet::create(
Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -45,6 +46,7 @@ public static function create(): RuleSet
$phpVersion,
Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php53Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php54Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php55Test.php
Expand Up @@ -39,6 +39,7 @@ final class Php55Test extends ExplicitRuleSetTestCase
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand Down Expand Up @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php56Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php70Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php71Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php72Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php73Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php74Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down
2 changes: 2 additions & 0 deletions test/Unit/RuleSet/Php80Test.php
Expand Up @@ -44,6 +44,7 @@ protected static function createRuleSet(): RuleSet
protected function expectedCustomFixers(): Fixers
{
return Fixers::fromFixers(
new Fixer\MultilineCommentOpeningClosingAloneFixer(),
new Fixer\PhpdocArrayStyleFixer(),
new Fixer\PhpdocTypeListFixer(),
new PhpCsFixer\Whitespace\LineBreakAfterStatementsFixer(),
Expand All @@ -68,6 +69,7 @@ protected function expectedRules(): Rules
{
return Rules::fromArray([
'ErickSkrauch/line_break_after_statements' => true,
'PhpCsFixerCustomFixers/multiline_comment_opening_closing_alone' => true,
'PhpCsFixerCustomFixers/phpdoc_array_style' => true,
'PhpCsFixerCustomFixers/phpdoc_type_list' => true,
'align_multiline_comment' => [
Expand Down

0 comments on commit 7a9143a

Please sign in to comment.