You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

11 lines
386 B

  1. module Rails
  2. module EngineExtensions
  3. # Rewrite task loading code to filter digitalocean.rake task
  4. def run_tasks_blocks(app)
  5. Railtie.instance_method(:run_tasks_blocks).bind(self).call(app)
  6. paths["lib/tasks"].existent.reject { |ext| ext.end_with?('digitalocean.rake') }.sort.each { |ext| load(ext) }
  7. end
  8. end
  9. end
  10. Rails::Engine.prepend(Rails::EngineExtensions)