Class: JekyllIndexPages::Author
- Inherits:
-
Jekyll::Generator
- Object
- Jekyll::Generator
- JekyllIndexPages::Author
- Defined in:
- lib/jekyll-index-pages/author.rb
Instance Method Summary collapse
Instance Method Details
#generate(site) ⇒ Object
5 6 7 8 9 10 |
# File 'lib/jekyll-index-pages/author.rb', line 5 def generate(site) = Hash.new { |hash, key| hash[key] = [] } = site.posts.docs.select { |doc| doc.data.key?("author") } .each { |doc| [doc.data["author"]] << doc } site.data["authors"] = end |