From a3c516c17c86f5695efd63638dde05dd8499f745 Mon Sep 17 00:00:00 2001 From: Zeh Rizzatti Date: Thu, 13 Dec 2012 01:30:46 -0300 Subject: [PATCH] show system ruby version as last resort on ruby-info --- modules/ruby/functions/ruby-info | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/ruby/functions/ruby-info b/modules/ruby/functions/ruby-info index 7bc8ead6..4dc7debf 100644 --- a/modules/ruby/functions/ruby-info +++ b/modules/ruby/functions/ruby-info @@ -18,6 +18,8 @@ if (( $+commands[rvm-prompt] )); then version="$(rvm-prompt)" elif (( $+commands[rbenv] )); then version="$(rbenv version-name)" +elif (( $+commands[ruby] )); then + version="$(ruby --version | cut -d' ' -f2)" fi # Format version.