Following those official instructions, I get either a permissions issue when the script tries to write to composer.json, or it can’t find that file as in the following case:
? composer config allow-plugins.dealerdirect/phpcodesniffer-composer-installer true
In ConfigCommand.php line 218:
File "./composer.json" cannot be found in the current directory
I’ve tried creating composer.json before running the command again, as well as changing its permissions and those of the parent directory, but no luck.
I’m on a Mac with an M2 chip.