forked from comfy/comfortable-mexican-sofa
-
Notifications
You must be signed in to change notification settings - Fork 0
/
comfortable_mexican_sofa.rb
46 lines (40 loc) · 1.37 KB
/
comfortable_mexican_sofa.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# Loading engine only if this is not a standalone installation
unless defined? ComfortableMexicanSofa::Application
require File.expand_path('comfortable_mexican_sofa/engine', File.dirname(__FILE__))
end
[ 'comfortable_mexican_sofa/version',
'comfortable_mexican_sofa/configuration',
'comfortable_mexican_sofa/http_auth',
'comfortable_mexican_sofa/rails_extensions',
'comfortable_mexican_sofa/controller_methods',
'comfortable_mexican_sofa/view_hooks',
'comfortable_mexican_sofa/view_methods',
'comfortable_mexican_sofa/form_builder',
'comfortable_mexican_sofa/acts_as_tree',
'comfortable_mexican_sofa/has_revisions',
'comfortable_mexican_sofa/is_mirrored',
'comfortable_mexican_sofa/tag',
'comfortable_mexican_sofa/fixtures'
].each do |path|
require File.expand_path(path, File.dirname(__FILE__))
end
Dir.glob(File.expand_path('comfortable_mexican_sofa/tags/*.rb', File.dirname(__FILE__))).each do |path|
require path
end
module ComfortableMexicanSofa
class << self
# Modify CMS configuration
# Example:
# ComfortableMexicanSofa.configure do |config|
# config.cms_title = 'ComfortableMexicanSofa'
# end
def configure
yield configuration
end
# Accessor for ComfortableMexicanSofa::Configuration
def configuration
@configuration ||= Configuration.new
end
alias :config :configuration
end
end