Then install rvm:
bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head )
or update rvm to the latest version:
rvm get head
Install ruby 1.9.3:
rvm install 1.9.3
rvm 1.9.3 --default
When I wanted to use octopress on github, after I “cd” into the local octopress directory, I was prompted to run the following command, because octopress declared to use ruby 1.9.2 in it’s “.rvmrc” file:
rvm install ruby-1.9.2-p318
But after I ran it, I got the following error:
The provided compiler '/usr/bin/gcc' is LLVM based, it is not yet fully supported by ruby and gems, please read `rvm requirements`.
I googled it and found the reason is Xcode 4.3 on Lion is incompatible with ruby 1.9.2. The solution came from here: just change 1.9.2 to 1.9.3 in the “.rvmrc” file.
Then you can use octopress on Lion, you may get the following warning message while run “rake generate” which will not affect the function:
MacBookAir:octopress user$ rake previewStarting to watch source with Jekyll and Compass. Starting Rack on port 4000