Ruby: Difference between revisions

From 太極
Jump to navigation Jump to search
Line 4: Line 4:
* I tried to install from the source (v2.2.1) on Ubuntu 14.04. The canonical method ./configure, make & sudo make install does not work at 'make' step. # See https://github.com/sstephenson/ruby-build/issues/690. Unfortunately the method of installing libffi-dev does not solve the error on Ubuntu 14.0.
* I tried to install from the source (v2.2.1) on Ubuntu 14.04. The canonical method ./configure, make & sudo make install does not work at 'make' step. # See https://github.com/sstephenson/ruby-build/issues/690. Unfortunately the method of installing libffi-dev does not solve the error on Ubuntu 14.0.
* The next method is [https://github.com/sstephenson/ruby-build#readme ruby-build]. Don't quite follow it.
* The next method is [https://github.com/sstephenson/ruby-build#readme ruby-build]. Don't quite follow it.
* http://stackoverflow.com/questions/26595620/how-to-install-ruby-2-1-4-on-ubuntu-14-04
 
http://stackoverflow.com/questions/26595620/how-to-install-ruby-2-1-4-on-ubuntu-14-04 mentioned a couple of methods.
* rbenv method. Not sure if it works since the shell hangs when I run 'rbenv install 2.2.0'.
* [http://rvm.io/ rvm (ruby version manager)] method.
<pre>
sudo apt-get update
sudo apt-get install build-essential make curl
\curl -L https://get.rvm.io | bash -s stable
source ~/.bash_profile
rvm install ruby-2.1.4
</pre>
The last step will take a while since no binary rubies were available and it has to compile Ruby from source.
 
Then check ruby versions installed and in use
<pre>
rvm list
rvm use --default ruby-2.1.4
</pre>


= Documentation =
= Documentation =
https://www.ruby-lang.org/en/documentation/
https://www.ruby-lang.org/en/documentation/

Revision as of 16:10, 13 March 2015

Installation on Ubuntu

http://stackoverflow.com/questions/26595620/how-to-install-ruby-2-1-4-on-ubuntu-14-04 mentioned a couple of methods.

sudo apt-get update
sudo apt-get install build-essential make curl
\curl -L https://get.rvm.io | bash -s stable
source ~/.bash_profile
rvm install ruby-2.1.4

The last step will take a while since no binary rubies were available and it has to compile Ruby from source.

Then check ruby versions installed and in use

rvm list
rvm use --default ruby-2.1.4

Documentation

https://www.ruby-lang.org/en/documentation/