I am facing a PHP_CodeSniffer Error. Can you please help me?

Viewed 1185

One of our engineers facing an error with PhpStorm. Whenever he edits anything in PhpStorm, it gives the error related to PHP_Codesniffer:

phpcs: env: php: No such file or directory...

If open PHPCodeSniffer Inspection Settings, the below attached settings can be seen.

Please click here to see the settings

One more point, it was working fine until he upgrades his MacOS from Big Sur to Monterey 12.0.1. Not sure this OS upgrade affect the application settings. Presently he cannot work with PhpStorm.

Could you please have a look and let me know?

1 Answers

One more point, it was working fine until he upgrades his MacOS from Big Sur to Monterey 12.0.1. Not sure this OS upgrade affect the application settings. Presently he cannot work with PhpStorm.

I had the same issue. Monterey removes the installed PHP version, as Mac OS no longer ships with php installed. Install php and it should work again.

In my case, using homebrew

brew install php@7.4
brew link php@7.4
Related