Uncategorized

Update rake For OS X

Rake is basically make for Ruby. I recently needed to update rake for something I was working on. After doing so, I tried to update some stuff in Profile Manager and it seemed to work on the outside, but a lot of stuff in Yosemite and Yosemite Server rely on rake so be careful when doing this kind of thing. So, to update to the latest version of rake, use the gem command along with the install verb and then rake as the gem being updated:

sudo gem update rake

This is an interactive command line environment so you’ll be asked a few questions in order to update the gem. Once complete, you’re running (at the time of this writing) 10.3.2. Run the list verb to see what version of each local gem you are running:

sudo gem list

Because running a newer version of rake can conflict with some built-in OS X stuff, you might find a desire to go back. At the time I’m writing this article, 0.9.6 is the latest and greatest version of rake that OS X uses. We can remove the existing rake using uninstall:

sudo gem uninstall rake

Then we can install a specific version using the install verb, followed by the gem and then the version:

sudo gem install rake 9.6

For a full guide of the gem verbs (or commands) see http://guides.rubygems.org/command-reference/.