Windows Installfest 3
Installing Ruby
- Run the following commands in order in the WSL terminal.
sudo apt-get uninstall rubyThis ensures that you will not be using any default version of Ruby that might have already been pre-installed and is likely old.sudo apt-get install git-core curl zlib1g-dev build-essential libssl-dev libreadline-dev libyaml-dev libsqlite3-dev sqlite3 libpq-dev libxml2-dev libxslt1-dev libcurl4-openssl-dev software-properties-common libffi-devgit clone https://github.com/rbenv/rbenv.git ~/.rbenvecho 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrcecho 'eval "$(rbenv init -)"' >> ~/.bashrcexec $SHELLgit clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-buildecho 'export PATH="$HOME/.rbenv/plugins/ruby-build/bin:$PATH"' >> ~/.bashrcexec $SHELLrbenv install 2.5.1(this can take a long time, ~10-30 minutes)rbenv global 2.5.1ruby -v
Installing Rails
- Install Ruby first as above, then run the following commands.
gem updategem update --systemgem install rails(this can take a long time, ~10 minutes)rbenv rehashrails -v