Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where is App::Application.load_tasks defined? [closed]

# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.

require File.expand_path('../config/application', __FILE__)

Dummy::Application.load_tasks

Given the above when making an engine, this dummy application also loads the engines tasks located in /lib/tasks as well. How does it do this? I can't seem to find where load_tasks is defined or how it works..

Any advice would be great.

like image 914
Senjai Avatar asked Nov 01 '22 12:11

Senjai


1 Answers

Type:

gem which rails

How is this? If you get /path/foo/gems/railties-4.0.0/lib/rails.rb or something, find there.

find /path/foo/gems/railties-4.0.0/lib -type f | xargs grep load_tasks
like image 81
takaurai Avatar answered Nov 09 '22 11:11

takaurai