You'll need RVM to isolate your development environment.
Make sure you install Ruby 1.9.2 p290
on your RVM.
Then just checkout the code, configure dependencies and run the tests:
- Clone the repository:
git clone https://github.com/crowdplaces/crowdplaces.git
- Enter the repo directory and accept the RVM:
cd crowdplaces
yes
gem install bundler
- Install all dependencies from Gemspec:
bundler install
- Create your database.yml:
cp config/database.sample.yml config/database.yml
- Create a role for the project:
psql -c "CREATE ROLE crowdplaces LOGIN CREATEDB;" -d postgres
- Create the local databases:
bundle exec rake db:create
- Download a recent pgbackup from Heroku and restore:
heroku pgbackups
curl -o db.dump `heroku pgbackups:url`
pg_restore --verbose --clean --no-acl --no-owner -U crowdplaces -d crowdplaces_development ./db.dump
pg_restore --verbose --clean --no-acl --no-owner -U crowdplaces -d crowdplaces_test ./db.dump
- Workaround a very strange error message "ERROR: must be owner of extension plpgsql":
psql -c "ALTER ROLE crowdplaces WITH superuser;" template1
The project supports multiple languages. Currently the website is available in English and Spanish.
For development matters, the Portuguese version is considered Master and is used as a reference for further translations so we can keep up to date with Catarse's code.
All translation happens via WebTranslateIt.
Config: wti init
and provide the private api key available at the project's settings on WebTranslateIt.
Updating: To update the project's code with translations made on the web:
cd config/locales && wti push && wti pull
- All commands must happen within the
config/locales
directory; - Make sure to push any local changes to the web before you pull updates. Otherwise you can loose your progress.