Skip to content

New contributor guide

Mackenzie edited this page Jun 22, 2016 · 13 revisions

To start contributing to Growstuff, you'll need to get the code and get a Ruby development environment setup. Here's how.

Get the code

  1. Sign up on Github
  2. Set up Git
  3. Click the "Fork" button above to fork this repo

Install web development environment

Database

  1. Install PostgreSQL

Ruby

  1. Install rvm
  2. Use rvm to install Ruby. In a terminal, go to your growstuff directory and run rvm install < .ruby-version
  3. Create a Ruby gemset. This holds the packages you need for growstuff separate from everything else. Run rvm gemset create < .ruby-gemset
  4. Install Bundler: gem install bundle

Install Growstuff

If you're using Mac OS X and installed PostgreSQL using Postgres.app, run this:

gem install pg -v '0.18.4' -- --with-pg-config=/Applications/Postgres.app/Contents/Versions/latest/bin/pg_config
  1. Run bundle install to install all the remaining dependencies.
  2. Create your test database: RAILS_ENV=development rake db:create
  3. Setup your test database: RAILS_ENV=development rake db:setup

Test it

If you run bundle exec rspec it should run all the tests and have no failures. Yay!

You can also run rails server then go to http://localhost:3000 in your web browser to try it out.

Clone this wiki locally