Why can't I set a default ruby with chruby in my .zprofile

709 Views Asked by At

After upgrading to Yosemite my ruby dev environment was not working well so I thought I would take the opportunity to switch to chruby from rbenv.

It's all gone pretty well after installing and I can switch between rubies easily, but I cannot set a default Ruby.

If I add the line chruby ruby-2.1.3 to my ~/.zprofile file then open a new terminal window I get the following error message;

/Users/brad/.zprofile:1: command not found: chruby

I have added source /usr/local/share/chruby/chruby.sh to my ~/.zshrc file as described in the configuration section for chruby. I'm not sure what else to do to get this working - I'm no expert at finding my way around shell config settings. Any clever ideas?

0

There are 0 best solutions below