Ruby PATH未正确设置

好的,所以我让Ruby完美地使用后卫来观看一些sass文件,我重新启动了我的电脑,苹果做了一些更新(不知道这是否与问题有关)。 一旦它重新启动,我就重新开启了防护,我收到了这个错误:

/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/universal-darwin13/rbconfig.rb:212: warning: Insecure world writable dir /usr/local/ImageMagick/bin in PATH, mode 040757 

现在一件非常明显的事情是在我的路径中间的’Imagemagick’,我不知道那是怎么到达那里的,并且相当确定这是我的问题。

当我尝试在Ruby中运行大多数事情时,我得到了这个:

 PATH is not properly set up, '/usr/local/rvm/gems/ruby-1.9.3-p448/bin' is not available, usually this is caused by shell initialization files - check them for 'PATH=...' entries, it might also help to re-add RVM to your dotfiles: 'rvm get stable --auto-dotfiles', to fix temporarily in this shell session run: 'rvm use ruby-1.9.3-p448'. 

rvm get stable --auto-dotfiles似乎没有为我做任何事情。 运行rvm info给我这条路径:

  PATH: "/usr/local/bin:/usr/local/sbin:/usr/local/mysql/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/ImageMagick/bin:/opt/sm/bin:/opt/sm/pkg/active/bin:/opt/sm/pkg/active/sbin:/usr/local/rvm/bin" 

只是想知道如何解决这条道路或任何可以解决我的问题的方法,我觉得我现在已经绕圈子走了太久了。

谢谢

我在OSX Mavericks上遇到了同样的问题。 对我有用的解决方案是将rvm路径添加到〜/ .bash_profile文件中的PATH环境变量。 在我的情况下,我没有系统范围的rvm安装,所以以下条目对我有用。

 PATH=/usr/local/bin:$HOME/.rvm/bin:$PATH 

有一些东西重置由rvm设置的PATH ,搜索你的shell初始化文件的PATH=不包含$PATH