Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save PurpleBooth/2dca748708cbf4862121eb66c1f325a3 to your computer and use it in GitHub Desktop.

Select an option

Save PurpleBooth/2dca748708cbf4862121eb66c1f325a3 to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash
composer validate
### Previous version
# php -r "\$lock = json_decode(file_get_contents('composer.lock'))->hash; \$json = md5(file_get_contents('composer.json')); if (\$lock !== \$json) { echo \"Lock file out of date\\n\"; exit(1); } echo \"Lock file up to date\\n\"; exit(0);"
@PurpleBooth
Copy link
Author

So today I learned about composer validate! Much tidier like this, rather than that horrible long string.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment