PHPCSStandards / composer-installer

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

GH Actions: add builds against Composer 2.2 for PHP 7.2 - 8.x #172

Closed jrfnl closed 2 years ago

jrfnl commented 2 years ago

Proposed Changes

Composer 2.3 drops support for PHP < 7.2, so for PHP 5.4 to 7.1, v2 will install Composer 2.2, for PHP 7.2 and up, v2 will install Composer 2.3. These extra builds make sure the Composer 2.2 LTS version will continue to be 100% supported for PHP 7.2-8.x.

Refs:

Test bootstrap: tweak the version determination regex

Apparently, Composer 2.3.0 dropped the word version from the --version output ;-)

Output on Composer 2.2 and lower:

Composer version 2.2.10 2022-03-29 21:55:35

Composer 2.3 output:

Composer 2.3.0 2022-03-30 11:15:36
jrfnl commented 2 years ago

As of Composer 2.3.3, the change in the second commit (test bootstrap) isn't strictly necessary anymore. Still doesn't do any harm either in case someone is running the tests locally and still has Composer 2.3.0 - 2.3.2 installed.

Refs: