Setting Up

Prasanna Pendse edited this page Jun 15, 2013 · 4 revisions

Setting Up

If you have never set up your Mac for Ruby development before, here are a simple set of steps to get you up and running with all the required pieces.

  1. Open the App Store, and search for 'Xcode'. Download and install, it's free.

  2. Launch Xcode and install any required System Components.

  3. Xcode > Preferences… Choose the Downloads toolbar item, choose the Components tab. Make sure Command Line Tools are installed.

  4. Launch Terminal.

  5. Install rvm: curl -L | bash -s stable --ruby

  6. Install Ruby 1.9.3: rvm install 1.9.3

  7. Switch to using the RVM installed Ruby: rvm use 1.9.3

  8. Install Bundler into the gemset for Ruby 1.9.3: gem install bundler

  9. Install Homebrew: ruby -e "$(curl -fsSkL"

  10. Install Node.js using Homebrew: brew install node

  11. Install the Android SDK using Homebrew: brew install android

These instructions assume you want to use Homebrew. If you have other ways you like to set up your Mac for development, please go ahead. As long as you have these dependencies installed, it doesn't really matter how they were installed.

Some useful android commands

  1. See what devices are connected (ie: does android know your emulator is up?): adb devices
  2. Don't find any devices that should be? Re-start adb server: adb kill-server adb start-server
  3. See a list of Android Virtual Devices (avd): android avd
  4. Start an emulator with a particular avd: emulator -avd nexus7