简体   繁体   English

安装nio4r(2.3.1)时发生错误-新鲜导轨安装

[英]An error occurred while installing nio4r (2.3.1) - fresh rails install

I'm installing rails on a new machine (high sierra to be exact) i've gone through the setup rails from go rails, however whenever i go to bundle install this is the following error: 我正在新机器上安装滑轨(准确地说是高山脉),我从go rails经历了安装滑轨,但是每当我捆绑安装时,都会出现以下错误:

Errno::EACCES: Permission denied @ dir_s_mkdir - /Users/jake/.rbenv/versions/2.5.0/lib/ruby/gems/2.5.0/extensions/x86_64-darwin-17/2.5.0-static/nio4r-2.3.1
An error occurred while installing nio4r (2.3.1), and Bundler cannot continue.
Make sure that `gem install nio4r -v '2.3.1'` succeeds before bundling.

I've downloaded command line tools, i've downloaded xcode (the actual app) I also accidentally downloaded postgres (via command line) first, before mysql. 我已经下载了命令行工具,我已经下载了xcode(实际的应用程序),我也意外地(在命令行之前)(通过命令行)下载了PostgreSQL,而在mysql之前。 I'm unsure whether this has anything to do with it 我不确定这是否与它有关

thanks in advance! 提前致谢!

It appears i've installed nio4r-2.3.1 in sudo, and therefore didn't have the correct permissions to access it when not in sudo. 看来我已经在sudo中安装了nio4r-2.3.1,因此当不在sudo中时,没有正确的权限访问它。 i ran the following command to change the directory: 我运行以下命令来更改目录:

sudo chown -R jake ~/.rbenv

big thanks to The Tin Man for his details post on this: - How to fix a bundle install "nio4r error" on Rails 5.0.0 非常感谢The Tin Man在此提供的详细信息:- 如何在Rails 5.0.0上修复捆绑安装“ nio4r错误”

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM