Created
July 15, 2012 13:09
-
-
Save janjongboom/3116835 to your computer and use it in GitHub Desktop.
Use Ruby 1.9.3 on Cloud9 IDE
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
**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 |
Can all instances of /var/lib/stickshift/GUID/app-root/data/
be safely replaced with $HOME
in the script above?
Yeah pretty sure.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@bm5k: Just tried it, seems to work for me. You may have to run
autoreconf -ivf
first.