• Basically the same as ruby 2.5.3 but I changed 2.5.3 to 2.6.1 and installed libreadline-dev
sudo apt-get update
sudo apt install -y libreadline-dev
sudo apt-get install build-essential
wget http://ftp.ruby-lang.org/pub/ruby/2.6/ruby-2.6.1.tar.gz
tar -xzvf ruby-2.6.1.tar.gz
cd ruby-2.6.1/
sudo apt-get install zlib1g-dev
sudo apt-get update -y && sudo apt-get upgrade -y
sudo apt-get install libssl-dev
sudo make install
ruby -v
sudo gem update --system
sudo gem install jekyll bundler
sudo gem install redcarpet

Leave a comment on github