Skip to content

Instantly share code, notes, and snippets.

@bidah bidah/start-learn
Created Aug 31, 2017

What would you like to do?
##Install Ruby Version Manager
RVM is a great tool that lets you run different versions of Ruby on your computer. This is really useful because if you know one project you're working on works with Ruby version 2.1.0 and another needs 2.3.0, you can easily switch between the two versions when you switch between projects. You can install it and set it up with the following commands:
Run `curl -sSL | bash` -make sure you do not use `sudo`
ONCE THIS STEP COMPLETES, CLOSE AND RE-OPEN YOUR TERMINAL. Skipping this step will cause RVM to not work.
Run `rvm install 2.3.1`
Run `rvm use 2.3.1 --default`
Check that everything worked by running `ruby -v` and `rvm list`. This should output the version of ruby you're using (2.3.1) and the list of versions available with your RVM install.
##Install some ruby gems
Ruby gems are pre written, stand alone, chunks of code that have been written and made easily accessible to you.
First, lets update our system gems with:
`gem update --system`
Install the gem bundler. This gem takes care of installing all the other gems you need for projects: `gem install bundler`
##Install some more gems!
If you're going to be doing web development on Learn, you're going to want to install a couple more gems.
Phantom JS is a JavasScript library and this ruby gem easily installs it for you:
`gem install phantomjs`
Nokogiri is a gem that let's us scrape websites and you'll definitely want to be able to use it. Let's install it with:
`gem install nokogiri`
##Install Rails
Finally, rails! The powerful ruby web framework. We can install that with:
`gem install rails`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.