class Dpl::Assets::Asset
Constants
- DIR
Public Instance Methods
copy(target)
click to toggle source
# File lib/dpl/helper/assets.rb, line 12 def copy(target) cp path, File.expand_path(target) end
exists?()
click to toggle source
# File lib/dpl/helper/assets.rb, line 20 def exists? File.exist?(path) end
path()
click to toggle source
# File lib/dpl/helper/assets.rb, line 28 def path "#{DIR}/#{namespace}/#{name}" end
read()
click to toggle source
# File lib/dpl/helper/assets.rb, line 16 def read exists? ? provider.interpolate(File.read(path)) : unknown end
unknown()
click to toggle source
# File lib/dpl/helper/assets.rb, line 24 def unknown raise "Could not find asset #{path}" end