Every now and then I make a change in my development environment and.. I am back at re-configuring the whole setup.
Let’s get that over with once and for all.
The setup that works
This is my environment:
- Visual Studio Code with
- PHP Sniffer by wongjn
- Composer with
- squizlabs/php_codesniffer
- wp-coding-standards/wpcs
The root of my workspace contains a phpcs.xml
that looks as follows:
PHPCS
.
*/app/www/vendor/*
*/app/frontend/node_modules/*
And a composer.json
file that sets the vendor dir to app/www/vendor
, as follows:
"config": {
"vendor-dir": "app/www/vendor"
}
Make sure you’re Workspace and General settings are empty!
- Check
.vscode/settings.json
in your workspace and clear it - Hit CMD (cntrl) + shift + P and enter ‘settings.json’ and check your custom settings to see if any PHPSniffer settings are active, clear them out if necessary
That’s it! That should do the job!
Leave a Reply