module FoxPage::Builders::Assets
Public Instance Methods
build_assets()
click to toggle source
# File lib/fox_page/builders/assets.rb, line 8 def build_assets all_assets.each do |asset| puts "ASSET\t#{asset}" app.sprockets.manifest.compile(asset) end end
Private Instance Methods
all_assets()
click to toggle source
# File lib/fox_page/builders/assets.rb, line 17 def all_assets app.config.assets + image_assets end
image_assets()
click to toggle source
# File lib/fox_page/builders/assets.rb, line 21 def image_assets image_assets_path = app.root.join("app/assets/images") Dir.glob("#{image_assets_path}/**/*.{png,jpg,gif,jpeg,svg}") .map { |full_path| full_path.sub(%r{\A#{image_assets_path}/}, "") } end