I am trying to install PHPCS (PHPCompatibity) in my PHPStrom. For that I have installed PHPCS using composer with the following command:
$ composer global require "squizlabs/php_codesniffer=*". In my Ubuntu 20.04, the path to phpcs executable is ~/.config/composer/vendor/bin.
But when I move inside the above folder and try to excute phpcs from the command line, I get this:
Command 'phpcs' not found, but can be installed with:
sudo apt install php-codesniffer
The phpcbs executable also resides in the same folder and I cannot run that as well.
When I am adding the above path to PHPStorm to validate PHPCS, the validation works fine.
In PHPStorm, I am getting this:
PHP_CodeSniffer
phpcs: ERROR: Referenced sniff "PHPCS23Utils" does not exist
Run "phpcs --help" for usage information
Open PHPCodeSniffer Inspection Settings
And when I run phpcs --help, I get Command not found error.
It is the first time I am trying to set these things up.
