Created
July 3, 2012 18:33
-
-
Save somebehemoth/3041681 to your computer and use it in GitHub Desktop.
This file contains 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/bash | |
# source rvm and .rvmrc if present | |
[ -s "$HOME/.rvm/scripts/rvm" ] && . "$HOME/.rvm/scripts/rvm" | |
[ -s "$PWD/.rvmrc" ] && . "$PWD/.rvmrc" | |
# precompile assets if any have been updated | |
if git diff-index --name-only HEAD | egrep '^app/assets' >/dev/null ; then | |
echo 'Precompiling assets...' | |
rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets | |
git add public/assets/* | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment