在RubyMotion允许混入? 我有两个文件的目录。 一个是一类,其他的模块。 当我包括在我的课模块(混入),我得到一个未找到错误。 在应用程序一切都在正确的RM自动要求?
谢谢你的帮助。
在RubyMotion允许混入? 我有两个文件的目录。 一个是一类,其他的模块。 当我包括在我的课模块(混入),我得到一个未找到错误。 在应用程序一切都在正确的RM自动要求?
谢谢你的帮助。
找到了! http://dylanmarkow.com/blog/2012/05/06/load-order-with-rubymotion/
我使用的捆扎机,所以我最终把这样的事情在Motion::Project::App.setup do |app|
块:
app_files = app.files.reverse.pop
app.files << Dir.glob(File.join(app.project_dir, 'lib/**/*.rb')) << app_files
肯定是有更好的方式来做到这一点。