Skip to content

Commit

Permalink
Remove DocBlockLineLengthFixer, as not used and often breaking, bette…
Browse files Browse the repository at this point in the history
…r handle manually (#24)
  • Loading branch information
TomasVotruba committed Jun 19, 2023
1 parent a39a1ac commit 1b33a8c
Show file tree
Hide file tree
Showing 18 changed files with 7 additions and 687 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,11 @@ composer require symplify/easy-coding-standard --dev

```diff
# ecs.php
use Symplify\EasyCodingStandard\Config\ECSConfig;
+use Symplify\EasyCodingStandard\ValueObject\Set\SetList;

return static function (ContainerConfigurator $containerConfigurator): void {
+ $containerConfigurator->import(SetList::SYMPLIFY);
return static function (ECSConfig $ecsConfig): void {
+ $ecsConfig->sets([SetList::SYMPLIFY]);
```

## Rules Overview
Expand Down
42 changes: 4 additions & 38 deletions docs/rules_overview.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# 13 Rules Overview
# 12 Rules Overview

## ArrayListItemNewlineFixer

Expand Down Expand Up @@ -43,42 +43,6 @@ Strict type declaration has to be followed by empty line

<br>

## DocBlockLineLengthFixer

Docblock lenght should fit expected width

:wrench: **configure it!**

- class: [`Symplify\CodingStandard\Fixer\LineLength\DocBlockLineLengthFixer`](../src/Fixer/LineLength/DocBlockLineLengthFixer.php)

```php
<?php

declare(strict_types=1);

use Symplify\CodingStandard\Fixer\LineLength\DocBlockLineLengthFixer;
use Symplify\EasyCodingStandard\Config\ECSConfig;

return static function (ECSConfig $ecsConfig): void {
$ecsConfig->ruleWithConfiguration(DocBlockLineLengthFixer::class, [DocBlockLineLengthFixer::LINE_LENGTH => 40]);
};
```


```diff
/**
- * Super long doc block description
+ * Super long doc
+ * block description
*/
function some()
{
}
```

<br>

## LineLengthFixer

Array items, method parameters, method call arguments, new arguments should be on same/standalone line to fit line length.
Expand All @@ -96,7 +60,9 @@ use Symplify\CodingStandard\Fixer\LineLength\LineLengthFixer;
use Symplify\EasyCodingStandard\Config\ECSConfig;

return static function (ECSConfig $ecsConfig): void {
$ecsConfig->ruleWithConfiguration(LineLengthFixer::class, [LineLengthFixer::LINE_LENGTH => 40]);
$ecsConfig->ruleWithConfiguration(LineLengthFixer::class, [
LineLengthFixer::LINE_LENGTH => 40,
]);
};
```

Expand Down
235 changes: 0 additions & 235 deletions src/Fixer/LineLength/DocBlockLineLengthFixer.php

This file was deleted.

45 changes: 0 additions & 45 deletions src/ValueObject/DocBlockLines.php

This file was deleted.

Loading

0 comments on commit 1b33a8c

Please sign in to comment.