Class: Giblish::CopyResourcesPreBuild

Inherits:
Object
  • Object
show all
Defined in:
lib/giblish/resourcepaths.rb

Overview

copy everything under cmd_opts.resource_dir to dst_top/web_assets/.

Instance Method Summary collapse

Constructor Details

#initialize(cmd_opts) ⇒ CopyResourcesPreBuild

required opts:

resource_dir

Pathname to the top of the resource area to be copied

style_name

basename of the css to use for styling

dstdir

Pathname to the destination dir where the copied resources will be

stored.



90
91
92
93
# File 'lib/giblish/resourcepaths.rb', line 90

def initialize(cmd_opts)
  @opts = cmd_opts.dup
  @paths = ResourcePaths.new(cmd_opts)
end

Instance Method Details

#on_prebuild(src_tree, dst_tree, converter) ⇒ Object



95
96
97
# File 'lib/giblish/resourcepaths.rb', line 95

def on_prebuild(src_tree, dst_tree, converter)
  copy_resource_area(@opts)
end