Solved: diff is not recognized as an internal or external command operable program or batch file

Hi, are you trying to use PHP_CodeSniffer to detect and fix errors but you get get the error:

`diff` is not recognized as an internal or external command operable program or batch file

To fix this errors, you can install Cygwin. But if you don't want install anything, you can add the command --no-patch

An example:

phpcbf --standard=Wordpress --no-patch index.php

Hope this will be helpful for you.









Leave a Comment