diaspora/config/ci/before-travis.sh
Jonne Hass 835c4447f6 I just want to see if this works :P
- Removed launchy since I couldn't find any use of it
- Ruby 1.9 seems to need em-synchrony explictly
- No need to recreate the Gemfile.lock on Travis if proper :platforms
options are used in the Gemfile
- Removed group :development, :test and moved the stuff in the
corresponding sections
- Install adapter Gems according to the env var DB, install al if it is
unset
- Merged database.yml.postgres into database.yml.example. Bonus point:
easier switching between mysql and postgres
- May break everything but lets see what CI says
2011-09-04 14:53:28 +02:00

31 lines
949 B
Bash
Executable file

# adjust GC settings for REE
export RUBY_HEAP_MIN_SLOTS=1000000
export RUBY_HEAP_SLOTS_INCREMENT=1000000
export RUBY_HEAP_SLOTS_GROWTH_FACTOR=1
export RUBY_GC_MALLOC_LIMIT=1000000000
export RUBY_HEAP_FREE_MIN=500000
# Install firefox
echo "Installing Firefox"
sudo aptitude -q3 -y install firefox
# Start xvfb in preparation for cucumber & jasmine
echo "Starting Xvfb"
sudo cp config/ci/xvfb /etc/init.d/xvfb
sh -e /etc/init.d/xvfb start
# Regenerate css files
echo "Regenerate CSS files"
bundle exec sass -q --update public/stylesheets/sass/:public/stylesheets/
# Create a database.yml for the right database
echo "Setting up database.yml for $DB"
cp config/database.yml.example config/database.yml
if [ "$DB" = "postgres" ]; then
sed 's/<<: *mysql/<<: *postgres/' config/database.yml > config/database.yml
fi
# Set up database
echo "Creating databases for $DB and loading schema"
bundle exec rake db:create
bundle exec rake db:schema:load