diff --git a/script/setup_growstuff.sh b/script/setup_growstuff.sh new file mode 100755 index 0000000..dd9ee1d --- /dev/null +++ b/script/setup_growstuff.sh @@ -0,0 +1,28 @@ +#!/bin/bash +# vim: sw=2 + +if [ $# -lt 1 ]; then + echo "Usage: $0 [GitHub username]" + exit 2; +fi + +curl -L https://get.rvm.io | bash -s stable +. ~/.rvm/scripts/rvm # uses bashisms +rvm install 1.9.3-p194 +rvm use 1.9.3-p194 +rvm --default 1.9.3-p194 +# rvm docs generate # not sure we actually need this -MRG +git clone https://github.com/$1/growstuff.git +cd growstuff/ +git remote add upstream https://github.com/Growstuff/growstuff.git +rvm use 1.9.3-p194 +rvm gemset create growstuffdev +rvm gemset use growstuffdev +gem install bundler +git checkout dev +bundle install +rake db:create +rake db:migrate +rake db:seed +rake db:test:prepare +rake && echo -e "Looks good! Now run\n\n. ~/.rvm/scripts/rvm\ncd growstuff\n"