Skip to content

Instantly share code, notes, and snippets.

@plexus
Created May 2, 2013 10:58
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save plexus/4194d8c47e9493019e04 to your computer and use it in GitHub Desktop.
Save plexus/4194d8c47e9493019e04 to your computer and use it in GitHub Desktop.
#!/bin/bash
set -e
export SANDBOX=/tmp/shoes_build
export PREFIX=${SANDBOX}/opt
export PATH=${PREFIX}/bin:${PATH}
export RUBY_VERSION=1.9.3-p392
export RUBY_HOME=${SANDBOX}/ruby-${RUBY_VERSION}
mkdir -p $PREFIX
function github() {
pushd $SANDBOX
[[ -d $2 ]] || git clone https://github.com/${1}.git $2
popd
}
sudo apt-get install git libcairo2-dev libpixman-1-dev libpango1.0-dev libgif-dev libjpeg-dev libgtk2.0-dev vlc libvlc-dev portaudio19-dev libsqlite3-dev libcurl4-openssl-dev libxslt1-dev makeself curl libxslt-dev libxml2-dev libcurl4-openssl-dev libungif4-dev ruby1.9.1-full
if [[ ! -d $RUBY_HOME ]] ; then
github sstephenson/ruby-build ruby-build
cd $SANDBOX/ruby-build
./install.sh
cd ..
ruby-build $RUBY_VERSION $RUBY_HOME
fi
github postmodern/chruby chruby
. $SANDBOX/chruby/share/chruby/chruby.sh
RUBIES=$RUBY_HOME chruby $RUBY_VERSION
github shoes/shoes red-shoes
gem install bundler
# ugly but it works
[[ -f ${RUBY_HOME}/lib/libruby*.so ]] || ln -s /usr/lib/libruby-1.9.1.so ${RUBY_HOME}/lib/libruby.so
cd $SANDBOX/red-shoes
bundle install
rake
echo "Find your new Shoes in $SANDBOX/red-shoes/dist !"
Copy link

ghost commented May 14, 2013

shoes-build.sh: 14: shoes-build.sh: Syntax error: "(" unexpected

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment