安装rvm时出现grep错误

时间:2011-09-26 05:07:20

标签: ruby git rvm

我在OS Lion 10.7.1上,从App Store安装了最新的XCode。我从dmg

安装了git 1.7.4

我正在尝试安装rvm。我在他们的主页上使用了这个命令

bash < <(curl -sk https://rvm.beginrescueend.com/install/rvm)

我得到一些grep错误,如下所示。出了什么问题?

shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
chdir: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Cloning into rvm...
remote: Counting objects: 5542, done.
remote: Compressing objects: 100% (2699/2699), done.
remote: Total 5542 (delta 3620), reused 3898 (delta 2115)
Receiving objects: 100% (5542/5542), 1.87 MiB | 411 KiB/s, done.
Resolving deltas: 100% (3620/3620), done.

  RVM:  Shell scripts enabling management of multiple ruby environments.
  RTFM: 
  HELP: 

Installing RVM to /Users/kl/.rvm/grep: ^hooks/[[:alpha:]]+_[[:alpha:]]+$: No such file or directory
**grep: ^hooks/[[:alpha:]]+_[[:alpha:]]+$: No such file or directory
grep: ^hooks/[[:alpha:]]+_[[:alpha:]]+$: No such file or directory
grep: ^_: No such file or directory**

Correct permissions for base binaries in /Users/kl/.rvm/bin...
Copying manpages into place.

  Notes for Darwin ( Mac OS X )
    For Snow Leopard be sure to have Xcode Tools Version 3.2.1 (1613) or later
    You should download the latest Xcode tools from developer.apple.com.
      (This is since the dvd install for Snow Leopard contained bugs).

If you intend on installing MacRuby you must install LLVM first.
If you intend on installing JRuby you must install the JDK.
If you intend on installing IronRuby you must install Mono
  (version 2.6 or greater is recommended).

To use an RVM installed Ruby as default instead of the system ruby:
rvm install 1.8.7 # installs patch 352: closest supported version
rvm system ; rvm gemset export system.gems ; rvm 1.8.7 ; rvm gemset import system # migrate your gems
rvm --default 1.8.7


NOTE:
As of 1.8.0 RVM once again loads .rvmrc files, by default, after asking your
permission to trust it of course.  If you do not wish to be enabled, simply set:
    export rvm_project_rvmrc=0
Within either your /etc/rvmrc or $HOME/.rvmrc file. This will turn off the
cd/pushd hooks when sourcing the rvm() function into your shell.


 Example: echo 'export rvm_project_rvmrc=0' >> $HOME/.rvmrc;
 (Then close the current shell and open a new one.)


Installation of RVM to /Users/kl/.rvm/ is complete.

1 个答案:

答案 0 :(得分:3)

圣洁的烟雾。这让我把头发拉了出来。删除.bashrc中的违规行

导出GREP_OPTIONS =' - color = auto'

像魅力一样安装。