Class: Depo::Config
- Inherits:
-
KungFigure::Base
- Object
- KungFigure::Base
- Depo::Config
show all
- Defined in:
- lib/depo/config.rb
Defined Under Namespace
Classes: BuildOptions, BuildProfile, Environments, Generators
Instance Method Summary
collapse
Instance Method Details
#builds_path ⇒ Object
22
23
24
|
# File 'lib/depo/config.rb', line 22
def builds_path
"#{root}/builds"
end
|
#buildscripts_path ⇒ Object
46
47
48
|
# File 'lib/depo/config.rb', line 46
def buildscripts_path
File.join(src_path,'util','buildscripts')
end
|
#dojo_version(*args) ⇒ Object
14
15
16
|
# File 'lib/depo/config.rb', line 14
def dojo_version(*args)
raise "dojo_version depricated."
end
|
#env_dj_config(env) ⇒ Object
38
39
40
|
# File 'lib/depo/config.rb', line 38
def env_dj_config(env)
return (env == "production") ? environments.productionDjConfig : environments.developmentDjConfig
end
|
#env_root_webpath(env) ⇒ Object
42
43
44
|
# File 'lib/depo/config.rb', line 42
def env_root_webpath(env)
return (env == "production") ? last_build_webpath : src_webpath
end
|
#last_build_webpath ⇒ Object
34
35
36
|
# File 'lib/depo/config.rb', line 34
def last_build_webpath
"#{base_webpath}#{(Dir[File.join(builds_path,'*')].max).to_s.gsub(webroot, "")}"
end
|
#root_webpath ⇒ Object
26
27
28
|
# File 'lib/depo/config.rb', line 26
def root_webpath
"#{base_webpath}#{root.gsub(webroot, "")}"
end
|
#src_path ⇒ Object
18
19
20
|
# File 'lib/depo/config.rb', line 18
def src_path
"#{root}/src"
end
|
#src_webpath ⇒ Object
30
31
32
|
# File 'lib/depo/config.rb', line 30
def src_webpath
"#{base_webpath}#{src_path.gsub(webroot, "")}"
end
|
#to_hash ⇒ Object
50
51
52
|
# File 'lib/depo/config.rb', line 50
def to_hash
@props
end
|