Skip to content

Instantly share code, notes, and snippets.

@kenichi
Created May 31, 2012 18:18
Show Gist options
  • Save kenichi/2845183 to your computer and use it in GitHub Desktop.
Save kenichi/2845183 to your computer and use it in GitHub Desktop.
who needs rvm?
# actually, fuck rvm...
OPT_RUBY_CURRENT=/opt/ruby/current
function opt_ruby_clear_current {
rm ${OPT_RUBY_CURRENT}
}
function opt_ruby_187 {
opt_ruby_clear_current
ln -s /opt/ruby/1.8.7-p358 ${OPT_RUBY_CURRENT}
hash -r
}
function opt_ruby_192 {
opt_ruby_clear_current
ln -s /opt/ruby/1.9.2-p320 ${OPT_RUBY_CURRENT}
hash -r
}
function opt_ruby_193 {
opt_ruby_clear_current
ln -s /opt/ruby/1.9.3-p194 ${OPT_RUBY_CURRENT}
hash -r
}
function opt_ruby_which {
ls -l /opt/ruby/current | cut -c 43-
ruby --version
}
alias wr=opt_ruby_which
alias 187=opt_ruby_187
alias 192=opt_ruby_192
alias 193=opt_ruby_193
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment