Last active
December 18, 2015 12:10
-
-
Save joxxoxo/5781189 to your computer and use it in GitHub Desktop.
deploy script
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
#!/usr/bin/env bash | |
# Load RVM into a shell session *as a function* | |
if [[ -s "$HOME/.rvm/scripts/rvm" ]] ; then | |
# First try to load from a user install | |
source "$HOME/.rvm/scripts/rvm" | |
elif [[ -s "/usr/local/rvm/scripts/rvm" ]] ; then | |
# Then try to load from a root install | |
source "/usr/local/rvm/scripts/rvm" | |
else | |
printf "ERROR: An RVM installation was not found.\n" | |
fi | |
echo 'before rvm use' | |
rvm use ruby-1.9.2-p320@deploy --create | |
echo 'after rvm use' | |
cd deploy_repository | |
git checkout master | |
git pull origin master | |
echo 'Before bundle install' | |
bundle install --no-deployment --without test | |
echo 'After bundle install' | |
cap deploy:migrations | |
echo "%%DONE%%" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment