Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我使用 rails-3.0.0.beta3 和 ruby-1.9.2-preview3。
我在 application_controller.rb 中定义了一些新方法,需要在控制台中进行测试。 如果我更改了 application_controller.rb 中的一些代码。 我必须重新启动控制台。 我曾尝试使用“重新加载!” 命令,只是不工作。 然后我使用“require 'application.rb'”, 仍然不起作用。 帮助!
确保您处于开发模式,然后尝试以下操作:
ActiveSupport::Dependencies.clear