Method 1 :
sudo apt-get install ruby
Method 2 :
1. Install essential package for development
sudo apt-get install build-essential zlib1g-dev
2. Download new and stable of ruby package from https://www.ruby-lang.org/
3. tar xvf ruby-2.1.1.tar.gz
4. Configuration and make install
cd ruby-2.1.1
Method A :
./configure
make
make install
Method B :
./configure -prefix=$HOME
make
make install
vim ./.bashrc
Add following command
# User specific environment and startup programs
PATH=$PATH:$HOME/bin
export PATH
0 意見:
張貼留言