[chruby] don't add rubies to chruby

chruby does that automatically. from documentation:

> When chruby is first loaded by the shell, it will auto-detect Rubies installed in /opt/rubies/ and ~/.rubies/
This commit is contained in:
Michal Cichra 2016-10-25 12:39:25 +02:00
commit c78a6e2b4b
No known key found for this signature in database
GPG key ID: 8F4BAE64224DE335

View file

@ -50,29 +50,17 @@ _source_from_omz_settings() {
fi
}
_chruby_dirs() {
local _chrubydirs=($HOME/.rubies/ $PREFIX/opt/rubies)
for dir in _chrubydirs; do
if [[ -d $dir ]]; then
RUBIES+=$dir
fi
done
}
function () {
local _chruby_homebrew_prefix=$(brew --prefix chruby) &> /dev/null
if _homebrew-installed && [ -r ${_chruby_homebrew_prefix} ] ; then
source ${_chruby_homebrew_prefix}/share/chruby/chruby.sh
source ${_chruby_homebrew_prefix}/share/chruby/auto.sh
_chruby_dirs
elif [[ -r "/usr/local/share/chruby/chruby.sh" ]] ; then
source /usr/local/share/chruby/chruby.sh
source /usr/local/share/chruby/auto.sh
_chruby_dirs
else
_source_from_omz_settings
_chruby_dirs
fi
}