Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DX: Improve internal dist config for Fixer #7952

Merged
merged 1 commit into from
Apr 16, 2024

Conversation

Wirone
Copy link
Member

@Wirone Wirone commented Apr 16, 2024

Utilise chained calls fully, without defining intermediate variables before.

@Wirone Wirone requested a review from kubawerlos April 16, 2024 15:09
@Wirone Wirone self-assigned this Apr 16, 2024
@Wirone
Copy link
Member Author

Wirone commented Apr 16, 2024

FYI: this change is inspired by my local version of the config (.php-cs-fixer.php), I just moved some of the changes to the dist file.

If you're not familiar, you can do something like this in your own config:

<?php

declare(strict_types=1);

use PhpCsFixer\Runner\Parallel\ParallelConfig;

ini_set('memory_limit', '-1');

/** @var \PhpCsFixer\Config $config */
$config = require __DIR__. '/.php-cs-fixer.dist.php';

return $config
//    ->setParallelConfig(ParallelConfig::detect())
    ->setFinder(
        $config
            ->getFinder()
            ->notPath([
                '.php-cs-fixer.php',
                'reproducer.php',
            ])
    )
;

@coveralls
Copy link

coveralls commented Apr 16, 2024

Coverage Status

coverage: 96.053%. remained the same
when pulling 66ed06d on Wirone:codito/improve-fixer-dist-config
into f40f18e on PHP-CS-Fixer:master.

.php-cs-fixer.dist.php Outdated Show resolved Hide resolved
@Wirone Wirone force-pushed the codito/improve-fixer-dist-config branch from e9887b1 to 62aa7fb Compare April 16, 2024 15:25
@Wirone Wirone enabled auto-merge (squash) April 16, 2024 15:29
@Wirone Wirone force-pushed the codito/improve-fixer-dist-config branch from 62aa7fb to 66ed06d Compare April 16, 2024 17:49
@Wirone Wirone merged commit 28209a2 into PHP-CS-Fixer:master Apr 16, 2024
26 checks passed
@Wirone Wirone deleted the codito/improve-fixer-dist-config branch April 16, 2024 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants