Skip to content

Instantly share code, notes, and snippets.

@tell-k
Created July 29, 2011 16:21
Show Gist options
  • Save tell-k/1114155 to your computer and use it in GitHub Desktop.
Save tell-k/1114155 to your computer and use it in GitHub Desktop.
install lokka+heroku part1
#!/bin/sh
########################################
# easy install lokka on heroku for MacOS
#
# filename: herokka1.sh
#
# dependencies
# - heroku account
# - bash
# - git
# - yasashisa
#
# see also
# - http://lokka.org/
#
# author: tell-k
# url: http://d.hatena.ne.jp/tell-k/
########################################
#set appname
if [ $1 ]; then
APPNAME=$1
else
echo 'pleate set heroku application name! ex) sh herokka1.sh [your application name]'
exit
fi
#rvm install
git clone --depth 1 git://github.com/wayneeseguin/rvm.git
cd ./rvm/
sh ./install
sh -c 'echo "[ -s ${HOME}/.rvm/scripts/rvm ] && source ${HOME}/.rvm/scripts/rvm" >> ~/.bashrc'
source ~/.bashrc
cd ../
rm -fr ./rvm
rvm install 1.9.2
rvm use 1.9.2 --default
rvm gemset create $APPNAME
#lokka download
git clone git://github.com/komagata/lokka.git $APPNAME
#write rvm settings in your .bashrc
sh -c "echo 'rvm use ruby-1.9.2@$APPNAME' >> './$APPNAME/.rvmrc'"
echo 'please type this command:'
echo " => rvm gemset use $APPNAME"
echo " => sh herokka2.sh $APPNAME"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment