Skip to content

Commit 7a1465d

Browse files
committed
README: update for Composer 2.2
Using the `dealerdirect/phpcodesniffer-composer-installer` Composer plugin is recommended to register external PHPCS standards with PHPCS. As of Composer 2.2.0, Composer plugins need to be explicitly allowed to run. This commit adds the CLI command to set those permissions to the installation instructions. Includes removing a few redundant `composer install`s. Refs: * https://blog.packagist.com/composer-2-2/#more-secure-plugin-execution
1 parent 3c6a691 commit 7a1465d

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

README.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,14 +38,13 @@ The minimum _recommended_ version of PHP_CodeSniffer is version 2.6.0.
3838

3939
If you don't have a Composer plugin installed to manage the `installed_paths` setting for PHP_CodeSniffer, run the following from the command-line:
4040
```bash
41+
composer config allow-plugins.dealerdirect/phpcodesniffer-composer-installer true
4142
composer require --dev dealerdirect/phpcodesniffer-composer-installer:"^0.7" phpcompatibility/phpcompatibility-all:"*"
42-
composer install
4343
```
4444

4545
If you already have a Composer PHP_CodeSniffer plugin installed, run:
4646
```bash
4747
composer require --dev phpcompatibility/phpcompatibility-all:"*"
48-
composer install
4948
```
5049

5150
Next, run:

0 commit comments

Comments
 (0)