I am working on a project that is using a very old version of PHP, and I wanted to set up linting for it in the Visual Studio Code editor without having to install PHP 5.3 on my system. This setup seems to work pretty well.
Created
July 21, 2016 18:40
-
-
Save kaleb/8b6fb95466cf994768bf13f23a1c873b to your computer and use it in GitHub Desktop.
Lint Old PHP Using Docker For Visual Studio Code
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"php.validate.executablePath": "scripts/php.sh" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
cat $8 | docker run --rm -i php:5.3 php -l -n -d display_errors=On -d log_errors=Off |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment