Created
June 11, 2019 02:31
-
-
Save ealden/bf33672f4cb221b9028ed0c4e804e148 to your computer and use it in GitHub Desktop.
Ruby install in Ubuntu 18.04 LTS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install dependencies as root | |
apt install -y build-essential libssl-dev libreadline-dev zlib1g-dev | |
# Install rbenv | |
git clone https://github.com/rbenv/rbenv.git ~/.rbenv | |
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bash_profile | |
echo 'eval "$(rbenv init -)"' >> ~/.bash_profile | |
source ~/.bash_profile | |
# Install ruby-build | |
git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build | |
# Install latest Ruby and set it as global | |
rbenv install 2.6.3 | |
rbenv global 2.6.3 | |
# Install bundler as we always need it | |
gem install bundler |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment