junstyle / vscode-php-cs-fixer

PHP CS Fixer extension for VS Code

Home Page:https://marketplace.visualstudio.com/items?itemName=junstyle.php-cs-fixer

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to force the extension to use the locally installed `php-cs-fixer` from the project (`executablePath`) instead of the default one ?

Alexandre-Fernandez opened this issue · comments

I installed php-cs-fixer locally and added some extensions.
This extension reads the config file, sees the extensions and throws because it can't import them.
This happens because it's not using the php-cs-fixer from the project. When I change my VSCode setting and change the executablePath to an absolute path to the project php-cs-fixer vendor executable it works again.

EDIT: The executable path that doesn't work is "php-cs-fixer.executablePath": "${extensionPath}/php-cs-fixer.phar".

yes. Cantor read the path of the php-cs-fixer that you install in the project. you must supply the path