After upgrading the version of ruby, when I tried rails s, I couldn't use the command.
$ rails --version rbenv: rails: command not found The `rails' command exists in these Ruby versions: 2.6.5
gem update --system
gem install bundler
gem install rails
Type rails -v in your terminal and you should see Rails 5.2.3.