How do I get a Rails 1.2.6 to automatically load code from app/*
-
09-07-2021 - |
Question
I have a Rails 1.2.6 application and I would like to be able to create a folder in app/ and have its contents loaded.
This is the behaviour of Rails 3. How can I achieve the same thing in Rails 1.2.6?
La solution
in config/environment.rb
config.load_paths += Dir["#{RAILS_ROOT}/app/jobs"]
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow