Class: EasyHtmlGenerator::Generator::Structure

Inherits:
Base
  • Object
show all
Defined in:
lib/easy_html_generator/generator/structure.rb

Overview

this generator creates dist paths

Instance Attribute Summary

Attributes inherited from Base

#config

Instance Method Summary collapse

Methods inherited from Base

#dest_path, #do_file, #do_input, #initialize, #input_to_output_file, #log, #log_running, #resolve_path_prefix, #should_do_file?, #src_path, #walk_files

Constructor Details

This class inherits a constructor from EasyHtmlGenerator::Generator::Base

Instance Method Details

#generateObject



10
11
12
13
14
15
16
17
18
19
# File 'lib/easy_html_generator/generator/structure.rb', line 10

def generate
  return unless @config.enabled

  log_running

  @project.config.paths.dist.each do |_index, dir|
    next if dir.empty?
    FileUtils.mkdir_p("#{@project.dist_path}/#{dir}")
  end
end