If you face issue when running ruby code in sublime like (sublime /bin/bash ruby command not found) Then just follow the below steps to run the code in Sublime.
$ type -p ruby
- /home/mypc/.rvm/rubies/ruby-2.4.0/bin/ruby
$ sudo ln -s /home/mypc/.rvm/rubies/ruby-2.4.0/bin/ruby /usr/local/bin/ruby
Then restart your sublime and run the ruby code.