Skip to content

Instantly share code, notes, and snippets.

@sycobuny
Created January 28, 2014 15:09
Show Gist options
  • Save sycobuny/8669292 to your computer and use it in GitHub Desktop.
Save sycobuny/8669292 to your computer and use it in GitHub Desktop.
Get the latest ruby version installed via RVM
RUBY_VER=$(rvm list strings | cut -d\- -f2 | sort -rn | head -n1) echo "ruby-$RUBY_VER-p$((for v in $(rvm list strings | grep "ruby-$RUBY_VER" | cut -d\- -f3); do; echo ${v[2,${#v}]}; done) | sort -rn | head -n1)"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment