Skip to content

Instantly share code, notes, and snippets.

@janjongboom
Created July 15, 2012 13:09
Show Gist options
  • Save janjongboom/3116835 to your computer and use it in GitHub Desktop.
Save janjongboom/3116835 to your computer and use it in GitHub Desktop.
Use Ruby 1.9.3 on Cloud9 IDE
**Cloud9 now has rvm, so you can switch easily (`rvm use X`), no need for this gist anymore**
# first thing to do is to get your VM's GUID
# do a 'pwd' in the console and grab the part after /var/lib/stickshift
# -> replace all GUID calls in this file :-)
create file: .gemrc
install: --no-rdoc --no-ri
update: --no-rdoc --no-ri
gemhome: /var/lib/stickshift/GUID/app-root/data/.gems
gempath:
- /var/lib/stickshift/GUID/app-root/data/gems/1.8
cp .gemrc ../
# install rvm
curl -L https://get.rvm.io | bash -s stable --ruby
# so this needs to be done every time apparently, add it to bashrc or something
# RUN IT IN TERMINAL! (Open via ALT+T)
source /var/lib/stickshift/GUID/app-root/data/.rvm/scripts/rvm
echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function' >> ~/.bash_profile
rvm use 1.9.3
ruby --version
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
Ruby is now in ~/.rvm/rubies/ruby-1.9.3-p194/bin/ruby in case you want to run it that way
# add to ~/.bashrc
source $HOME/.rvm/scripts/rvm
echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function' >> ~/.bash_profile
rvm use 1.9.3
@janjongboom
Copy link
Author

Yeah pretty sure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment