Method: Burr::Book#initialize
- Defined in:
- lib/burr/book.rb
#initialize(config, format) ⇒ Book
Returns a new instance of Book.
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
# File 'lib/burr/book.rb', line 10 def initialize(config, format) @config = config @format = format @ui = Burr::UI.new # directory location @gem_dir = File.('../../../' ,__FILE__) @root_dir = Dir.pwd @outputs_dir = "#{@root_dir}/outputs" @caches_dir = "#{@root_dir}/caches" @contents_dir = "#{@root_dir}/contents" @plugins_dir = "#{@root_dir}/plugins" @templates_dir = "#{@root_dir}/templates" # publishing process variables @items = [] @toc = '' @images = [] @tables = [] @current_item = [] # labels and titles book_labels # @labels = {}, @ids = [] book_titles # @titles = {} # book information book_uid # @uid = '' book_slug # @slug = '' end |