Skip to content

Instantly share code, notes, and snippets.

@fbrinker
Last active November 20, 2017 10:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fbrinker/eb8ecf28950732539b8f4bf33fa208ce to your computer and use it in GitHub Desktop.
Save fbrinker/eb8ecf28950732539b8f4bf33fa208ce to your computer and use it in GitHub Desktop.
Lint all php files and invert the grep return code so a CI build can fail on found errors
#!/usr/bin/env bash
find . -type f -name '*.php' -exec php -l {} \; | (! grep -v "No syntax errors detected" )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment