Skip to content

Instantly share code, notes, and snippets.

@jewilmeer
Last active January 11, 2020 22:57
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jewilmeer/41238314b38eae13a5d1 to your computer and use it in GitHub Desktop.
Save jewilmeer/41238314b38eae13a5d1 to your computer and use it in GitHub Desktop.
The build script we use at traintool.com
if ! type phantomjs; then
echo "phantomjs not installed, now installing"
cd /usr/local/share
sudo wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-1.9.7-linux-x86_64.tar.bz2
sudo tar xjf phantomjs-1.9.7-linux-x86_64.tar.bz2
sudo ln -s /usr/local/share/phantomjs-1.9.7-linux-x86_64/bin/phantomjs /usr/local/share/phantomjs
sudo ln -s /usr/local/share/phantomjs-1.9.7-linux-x86_64/bin/phantomjs /usr/local/bin/phantomjs
sudo ln -s /usr/local/share/phantomjs-1.9.7-linux-x86_64/bin/phantomjs /usr/bin/phantomjs
else
echo "phantomjs installed, continue"
echo "`phantomjs --version`"
fi
if ! type mysqld; then
sudo apt-get update
sudo apt-get -y install mysql-server mysql-client libmysqlclient-dev
# time zone support
mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root mysql
fi
ruby -v
bundle --without development production --quiet
cp config/database{.ci,}.yml
rake db:create db:schema:load db:test:prepare
rake test && ./bin/cucumber
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment