刚买了一个新的 macbook pro,我在安装 rails 时遇到了麻烦。我已经安装了 ruby 1.8.7,当我尝试编写“gem install rails”时,我得到:
ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions into the /Library/Ruby/Gems/1.8 directory.
我还尝试安装更高版本的 ruby,它说:
Nirs-MacBook-Pro:~ nirohayon$ rvm install 1.9.3
Fetching yaml-0.1.4.tar.gz to /Users/nirohayon/.rvm/archives
Extracting yaml-0.1.4.tar.gz to /Users/nirohayon/.rvm/src
Configuring yaml in /Users/nirohayon/.rvm/src/yaml-0.1.4.
Error running ' ./configure --prefix="/Users/nirohayon/.rvm/usr" ', please read /Users/nirohayon/.rvm/log/ruby-1.9.3-p125/yaml/configure.log
Compiling yaml in /Users/nirohayon/.rvm/src/yaml-0.1.4.
Error running 'make ', please read /Users/nirohayon/.rvm/log/ruby-1.9.3-p125/yaml/make.log
Database file /Users/nirohayon/.rvm/config/packages does not exist.
Installing Ruby from source to: /Users/nirohayon/.rvm/rubies/ruby-1.9.3-p125, this may take a while depending on your cpu(s)...
ruby-1.9.3-p125 - #fetching
ruby-1.9.3-p125 - #extracted to /Users/nirohayon/.rvm/src/ruby-1.9.3-p125 (already extracted)
ruby-1.9.3-p125 - #configuring
Error running ' ./configure --prefix=/Users/nirohayon/.rvm/rubies/ruby-1.9.3-p125 --enable-shared --disable-install-doc --with-libyaml --with-opt-dir=/Users/nirohayon/.rvm/usr ', please read /Users/nirohayon/.rvm/log/ruby-1.9.3-p125/configure.log
There has been an error while running configure. Halting the installation.
ls: /Users/nirohayon/.rvm/rubies/*/bin/ruby: No such file or directory
请帮助我,我以前使用过 Windows,而且对 Rails 也很陌生,所以我不太了解应该引导我的终端的路径。我需要一步一步的解释来安装导轨并站在我的 Mac 上。
非常感谢!尼尔