Skip to content

Instantly share code, notes, and snippets.

@frullah
Created December 25, 2020 16:26
Show Gist options
  • Save frullah/9c5b0d162a221693ba60337f11fab59a to your computer and use it in GitHub Desktop.
Save frullah/9c5b0d162a221693ba60337f11fab59a to your computer and use it in GitHub Desktop.
rbenv installation in bash
#!/bin/bash
#
# simplified version of https://www.techiediaries.com/install-ruby-2-7-rails-6-ubuntu-20-04/
#
# make sure you have install all requisite libraries
# see https://github.com/rbenv/ruby-build/wiki#suggested-build-environment
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
exec $SHELL
git clone https://github.com/rbenv/ruby-build.git "$(rbenv root)"/plugins/ruby-build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment