ruby on rails “usr/bin/env: ‘ruby2.3’: No such file or directory”

自闭症网瘾萝莉.ら 提交于 2019-12-07 11:27:34

问题


I got some problem when i typing bundle exec rake db:migrate on terminal then i received the result like `/usr/bin/env: ‘ruby2.3’: No such file or directory


回答1:


I had the same problem but when running:

rails new my_application

but after reinstalling the rails gems by:

gem install rails

it worked just fine and I could run:

rails new my_application
bundle install

and

bundle exec rails s

without any problems.




回答2:


For me, the problem was with a cached set of gems (on CircleCI 2.0). I changed my base image which changed the ruby location. If you tried to bundle install with one ruby, removed it then switched to another, then this appears to cause the problem.



来源:https://stackoverflow.com/questions/40386726/ruby-on-rails-usr-bin-env-ruby2-3-no-such-file-or-directory

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!