Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP


Add /usr/local/opt/rubies to default search path. #76

wants to merge 5 commits into from

2 participants


I've updated the code and README to /usr/local/opts/rubies instead of /usr/local/rubies.

@colinrymer colinrymer closed this
@colinrymer colinrymer reopened this

Doesn't homebrew use /usr/local/opt/? I know it installs package symlinks into /usr/local/.


Homebrew does use /usr/local/opt/ (and various other directories in /usr/local/), which is the motivation for the addition of /usr/local/... to the search paths; it keeps the rubies out of Userland, without requiring them to be in /opt/.


I'm going to close this. Homebrew has claimed /usr/local/opt as there own, and users probably shouldn't be messing around in there. However, users can manually set RUBIES pointing to specific Ruby installations within /usr/local/opt/.

@postmodern postmodern closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 1 deletion.
  1. +1 −1 
  2. +1 −0  share/chruby/
2 
@@ -74,7 +74,7 @@ Add the following to the `/etc/profile.d/`, `~/.bashrc` or
source /usr/local/share/chruby/
-By default chruby will search for Rubies installed into `/opt/rubies/` or
+By default chruby will search for Rubies installed into `/opt/rubies/`, `/usr/local/opt/rubies/`, or
`~/.rubies/`. For non-standard installation locations, simply set the
`RUBIES` variable:
1  share/chruby/
@@ -1,6 +1,7 @@
typeset -a RUBIES
[[ -d /opt/rubies/ ]] && RUBIES+=(/opt/rubies/*)
+[[ -d /usr/local/opt/rubies/ ]] && RUBIES+=(/usr/local/opt/rubies/*)
[[ -d "$HOME/.rubies" ]] && RUBIES+=("$HOME"/.rubies/*)
function chruby_reset()
Something went wrong with that request. Please try again.