14
2
I'm learning rails from different books that use different versions of both ruby and rails. Right now I have ruby 1.87 installed on my Mac OS X Snow Leopard (in /usr/bin
), but need to also use ruby 1.9 for a different rails application.
Can anyone tell me how to make this work? I'm new to this, so as many instructions as possible would be greatly appreciated.
It appears the link to RVM needs updated: https://rvm.io/
– Jacob Ewald – 2016-01-04T16:51:53.7071
See also rbenv.
– user1686 – 2011-09-27T17:44:53.840@grawity Why not post another answer? Good to have alternatives, haven't really looked into
rbenv
yet. – slhck – 2011-09-27T17:47:10.033thanks so much, does it also help switch between versions of Rails? different books I'm using employ 3.05 (I think) and 3.1 and it's causing problems... – Michael – 2011-09-27T18:14:42.853
I tried the install line you wrote (and which is also on rvm site) and got an error message: bash: line 152: git: command not found bash: line 154: git: command not found – Michael – 2011-09-27T18:17:57.937
Ah, you need
– slhck – 2011-09-27T18:22:52.903git
, of course. Sorry, I forgot that. You can install Git with the OS X installer (just select the latest version at the top).And yes, Rails is in essence just a gem (together with others), so you can switch it with Named Gem Sets as explained in the RVM manual – even specifically for the Rails case. @Michael
– slhck – 2011-09-27T18:23:59.520this is weird, the commments appear and disappear. I thought you had a comment here that linked to the git installer... – Michael – 2011-09-27T18:26:06.580
thanks a lot. Git comes iwth a file "set up git for non-terminal programs". There's a bit of code in there...should I put it somewhere? – Michael – 2011-09-27T18:29:50.647
@Michael See the part in
README
for that. You don't need it, but it doesn't hurt to have it. Just open that file with a Terminal. If it's too complicated, just skip that part. – slhck – 2011-09-27T19:16:03.017