Class: ArchiveDisplayTag::ArchiveDisplay
- Inherits:
-
Liquid::Tag
- Object
- Liquid::Tag
- ArchiveDisplayTag::ArchiveDisplay
- Defined in:
- archive_display.rb
Instance Method Summary collapse
-
#initialize(tag_name, archive_name, tokens) ⇒ void
constructor
Constructor.
-
#render(context) ⇒ String
Method prescribed by the Jekyll plugin lifecycle.
Constructor Details
#initialize(tag_name, archive_name, tokens) ⇒ void
Constructor.
28 29 30 31 32 |
# File 'archive_display.rb', line 28 def initialize(tag_name, archive_name, tokens) super archive_name.strip! @archive_name = archive_name end |
Instance Method Details
#render(context) ⇒ String
Method prescribed by the Jekyll plugin lifecycle.
36 37 38 39 40 41 |
# File 'archive_display.rb', line 36 def render(context) source = context.registers[:site].config['source'] tar_name = "#{source}/#{@archive_name}" ArchiveDisplayTag.log.info "archive_display: tar_name=#{tar_name}" traverse_tar(tar_name) end |