Installing Mac OS Ruby using rvm

Source: Internet
Author: User

Http://www.ruby-lang.org/en/downloads/ access
After installing Ruby with a third-party tool, you can use macports and rvm to install Ruby on Mac.
After actual operations, I think the rvm method is better.
Now start to use rvm to install Ruby
1. Open the terminal and install git first.

Java code
  1. Bash-s stable <(curl-s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer)

,
2. After the rvm is installed, configure the environment variable and enter it in the current user directory.

Java code
  1. Sudo Vim. bash_profile


Add the. bash_profile File

Java code
  1. [[-S "$ home/. rvm/scripts/rvm"] & source "$ home/. rvm/scripts/rvm"


You can use rvm after the source operation.
3. start installing Ruby.
View resources.

Java code
  1. Rvm List known


4. Install Ruby

Java code
  1. Rvm install ruby -- head


5. Use Ruby

Java code
  1. Rvm use 1.9.3 -- default


5. Change Source

Java code
  1. Gem update -- System
  2. Gem uninstall rubygems-Update
  3. Gem sources-r http://rubygems.org/
  4. Gem sources-A http://ruby.taobao.org


6. Install rails

Java code
  1. Gem install rails-V


-V view Process

Installing Mac OS Ruby using rvm

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.