PHPCSStandards / composer-installer

Composer installer for PHP_CodeSniffer coding standards
https://packagist.org/packages/dealerdirect/phpcodesniffer-composer-installer
MIT License
542 stars 36 forks source link

Switch to PHPCSStandards/PHP_CodeSniffer #214

Closed jrfnl closed 7 months ago

jrfnl commented 7 months ago

This is a DRAFT PR on purpose as it references releases which have not yet been tagged. Once the PHPCS 3.8.0 tag is available (which contains the Composer replace directive), this can/should be merged and released ASAP.

Proposed Changes

Switch to PHPCSStandards/PHP_CodeSniffer

The Squizlabs repo has been abandoned. The project continues in a fork in the PHPCSStandards organisation.

Note: I'm not changing the version constraints. All tags since 2.0.0 have been recreated in the PHPCSStandards fork, though the package name in those tags has not been changed.

Based on tests I've run, the package should install fine when old tags are requested, though if a user has a composer.json which also includes squizlabs/php_codesniffer in their dependency chain, this means that both will be installed, which could lead to issues.

I recommend tagging a release straight-away. This should then allow our dependencies to update their own requirements and version constraints and to release once PHPCS 3.8.0 has been tagged, to prevent these type of problems.

Ref:

Tests/PHPCSVersions: add PHPCS 3.7.2/3.8.0 to the mix

Refs:

Revert changes to the Composer package name

In contrast to earlier information, arrangements are now being made to allow the package to continue under its original name on Packagist. The commit (in the new repo) to rename the package has been reverted.

jrfnl commented 7 months ago

Update: The Composer package name will not change, so while this PR should still be merged at our convenience (after the 3.8.0 release expected this Friday), we will not need to do a release to unblock end-users

jrfnl commented 7 months ago

PHPCS 3.8.0 has just been released.

I've re-retriggered the build and if it passes, I will merge this PR.