mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-23 10:40:13 +01:00
Removed superfluous 'tracks' directory at the root of the repository.
Testing commits to github.
This commit is contained in:
parent
6a42901514
commit
4cbf5a34d3
2269 changed files with 0 additions and 0 deletions
26
vendor/rails/railties/lib/console_with_helpers.rb
vendored
Normal file
26
vendor/rails/railties/lib/console_with_helpers.rb
vendored
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
class Module
|
||||
def include_all_modules_from(parent_module)
|
||||
parent_module.constants.each do |const|
|
||||
mod = parent_module.const_get(const)
|
||||
if mod.class == Module
|
||||
send(:include, mod)
|
||||
include_all_modules_from(mod)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
def helper(*helper_names)
|
||||
returning @helper_proxy ||= Object.new do |helper|
|
||||
helper_names.each { |h| helper.extend "#{h}_helper".classify.constantize }
|
||||
end
|
||||
end
|
||||
|
||||
require 'application'
|
||||
|
||||
class << helper
|
||||
include_all_modules_from ActionView
|
||||
end
|
||||
|
||||
@controller = ApplicationController.new
|
||||
helper :application rescue nil
|
||||
Loading…
Add table
Add a link
Reference in a new issue