Skip to content

Contributing

Joel Graycar edited this page Apr 25, 2015 · 8 revisions

Contributing to development

If you're thinking of working on the code base for the website, this is the page for you! These steps assume you're a member of the Cal Raijin Taiko GitHub organization, though there aren't too many differences if you're not. (A brief outline: fork the repo, set up the upstream remote, and then submit pull requests when you've got something.)

Initial Setup

First things first: you'll only be able to work on the website using a Mac or Linux machine. Sorry PC lovers! As far as I know, Windows doesn't support the most recent versions of Ruby, so you're out of luck. That being said, you could always run a Linux VirtualBox if you really wanted to (instructions).

Installing Dependencies

  1. Install rvm by following these instructions

  2. Install the correct version of ruby:

    rvm install ruby-2.2.0
    rvm use ruby-2.2.0

    to download ruby v2.2.0 and begin using it.

    Note: if you encounter the error

    RVM is not a function, selecting rubies with 'rvm use ...' will not work
    

    try running the commands

    source ~/.rvm/scripts/rvm
    type rvm | head -n 1

    If that outputs rvm is a function, then run the command

    echo [[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"' >> ~/.bashrc

    And you should be all good! If you're getting this problem on Ubuntu, try following these instructions

  3. Install Bundler by running the command gem install bundler

  4. Install Imagemagick:

    On Mac:

    Install Homebrew with the following command:

    ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

    Once Homebrew is installed, run

    brew install imagemagick

    On Ubuntu:

    sudo apt-get install imagemagick

Setting up your local version of the website

  1. Clone the repo:

    Navigate into the directory where you'll want the project to live, then run the command

    git clone [email protected]:calraijintaiko/caltaiko.git
  2. Run the command

    bundle install

    to install all of the project's gems

  3. Run the commands

    rake db:schema:load
    rake db:seed

    to set up the test and development databases, as well as populate them with some fake data.

Clone this wiki locally