blob: bfafc4742d8400d786a636af6b0ce46550ba42a0 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
module Capistrano
module RefineryCMS
module Helpers
def refinerycms_template(template_name)
f = File.join(fetch(:refinerycms_template_path), 'template_name')
unless File.exists?(f)
default_template_path = File.join(%W{ .. .. generators capistrano refinerycms templates #{ template_name } })
f = File.expand_path(default_template_path, __FILE__)
end
template = File.read(f)
StringIO.new(ERB.new(template).result(binding))
end
end
end
end
|