Method: Zine::PostsAndHeadlines#initialize

Defined in:
lib/zine/posts_and_headlines.rb

#initialize(site, options) ⇒ PostsAndHeadlines

Returns a new instance of PostsAndHeadlines.



12
13
14
15
16
17
18
19
20
21
22
# File 'lib/zine/posts_and_headlines.rb', line 12

def initialize(site, options)
  @options = options
  @post_array = []
  @site = site
  @tags_by_post = []
  dir = @options['directories']
  @guard = Zine::Watcher.new self, dir['build'], dir['source']
  @guard.start
  read_post_markdown_files
  sort_posts_by_date
end