dealerdirect/phpcodesniffer-composer-installer is a commonly used composer plugin to make it easy to import phpcs standards via composer.
For that plugin to be able to recognize mediawiki/mediawiki-codesniffer as being a package containing phpcs standards, composer.json needs to declare the type as being "phpcodesniffer-standard".
The change needed is very simple:
diff --git a/composer.json b/composer.json index c24cc68..66cc3bf 100644 --- a/composer.json +++ b/composer.json @@ -7,6 +7,7 @@ ], "homepage": "https://www.mediawiki.org/wiki/Manual:Coding_conventions/PHP", "license": "GPL-2.0-or-later", + "type": "phpcodesniffer-standard", "require": { "php": ">=7.2.0", "ext-mbstring": "*",
I'd submit that to Gerrit myself, but my Gerrit account seems to be non-functional.