Every time I run this command rails server:

warning: Insecure world writable dir /usr/local/bin in PATH, mode 040777

I searched for a solution here and they said to type: chmod go-w /usr/local/bin

But I get this error:

chmod: Unable to change file mode on /usr/local/bin: Operation not permitted

I am using OS X by the way.

推荐答案

You will need to have root access to do this. If you aren't already the administrative user, login as the administrator. Then use 'sudo' to change the permissions:

sudo chmod go-w /usr/local/bin

Obviously, that will mean you can no longer install material in /usr/local/bin except via 'sudo', but you probably shouldn't be doing that anyway.

Ruby-on-rails相关问答推荐

为什么这个rails Collection_select不呈现关联属性?

使用FactoryBot测试ActiveStorage的RSpec请求规范

在URL中将下划线更改为连字符Ruby on Rails

Rails - Comment.count没有改变1

从 rails 5 迁移到 rails 6

2个空格或1个制表符,Rails社区的缩进标准是什么?

在 rails 3 中设置记录器

使用 rails 3.1.0 和 ubuntu 安装 Nokogiri 1.5.0 时出错

如何判断是否已经在 ruby​​ on rails 的数据库事务中?

Rails 3:如何正确显示textarea中的文本?

Rails 模型:您将如何创建一组预定义的属性?

Rails:设计:按角色登录后重定向

如何在rails中发回js.haml

如何解决弃用警告方法 to_hash 已弃用并将在 Rails 5.1 中删除

如何在 Rails 中验证日期以使其在今天之后?

rails structure.sql和schema.rb有什么区别

如何测试自定义验证器?

如何设置 MiniTest?

ruby on rails 如何处理 NaN

Rails:您已经激活了 rake 10.3.1,但您的 Gemfile 需要 rake 10.2.2 (Gem::LoadError)