Created
February 14, 2013 01:20
-
-
Save mtibben/4949919 to your computer and use it in GitHub Desktop.
Hook to tell you when to run a composer install. Put this in your .git/hooks/post-checkout
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
#!/usr/bin/env bash | |
file="composer.lock" | |
if [[ $(git diff HEAD@{1}..HEAD@{0} -- "${file}" | wc -l) -gt 0 ]]; then | |
echo | |
echo -e "======> \033[33m${file}\033[0m has changed! Execute \033[32mcomposer install --dev\033[0m" | |
echo | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment