13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
# File 'lib/boot.rb', line 13
def setup_application(options = {})
Logger.setup :logfile => File.expand_path(options[:logfile], Dir.pwd),
:level => (options[:loglevel]).to_sym
Logger.info "Setting up Application"
Configs.set :options => options,
:wdir => Dir.pwd,
:output => File.absolute_path(options[:output]),
:templates => File.absolute_path(options[:templates]),
:includes => (options[:includes] && File.absolute_path(options[:includes])),
:files => (options[:files] && options[:files].map {|path| Dir.glob(path) }.flatten),
:docs => (options[:docs] && options[:docs].map {|path| Dir.glob(path) }.flatten)
Logger.debug "Given options: #{options}"
Logger.debug "App Root: #{Configs.root}"
Logger.debug "Working Dir: #{Configs.wdir}"
Logger.debug "Output Dir: #{Configs.output}"
end
|