Steps for Rails installation | How to install rails by abhishek singh
100% worked for me so I'm sharing this. Every line is a separate command so copy each line and execute. sudo add-apt-repository ppa:webupd8team/atom -y sudo apt-get update && sudo apt-get upgrade sudo apt-get install -y curl git openssl postgresql libpq-dev sqlite redis-server sudo apt-get install -y vim atom cd git clone git://github.com/sstephenson/rbenv.git .rbenv echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc echo 'eval "$(rbenv init -)"' >> ~/.bashrc exec $SHELL git clone git://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build echo 'export...