How to Check ruby Version by CLI and File?

Today, We want to share with you checking ruby version.In this post we will show you install ruby, hear for install ruby mac we will give you demo and example for implement.In this post, we will learn about How To Check If A File Exists In Ruby? with an example.

how to check ruby version?

Example 1: how to check ruby version

// here find to Command line:
$ ruby -v

// Within irb type "RUBY_VERSION"
# => "2.4.1"

// If using RVM:
$ rvm current
# => ruby-2.4.1

check all ruby version ubuntu

Example 2:

rvm list

rvm rubies
   ruby-1.9.1-p431 [ i386 ]
=* ruby-1.9.2-p320 [ i386 ]
# => - current
# =* - current && default
#  * - default

I hope you get an idea about Ruby on Rails – Installation.
I would like to have feedback on my infinityknow.com blog.
Your valuable feedback, question, or comments about this article are always welcome.
If you enjoyed and liked this post, don’t forget to share.

Leave a Comment