class Jekyll::FlickrPhotosetTag

Public Class Methods

new(tag_name, markup, tokens) click to toggle source
Calls superclass method
# File lib/badpixxel-jekyll-flickr.rb, line 117
def initialize(tag_name, markup, tokens)
    super
    params = Shellwords.shellwords markup
    title = params[0]
    @slug = title.downcase.gsub(/ /, '-').gsub(/[^a-z\-]/, '')
end

Public Instance Methods

render(context) click to toggle source
# File lib/badpixxel-jekyll-flickr.rb, line 124
def render(context)
    site = context.registers[:site]
    Jekyll::flickr_setup(site)
    file_photoset = File.join(site.config['flickr']['cache_dir'], "#{@slug}.yml")
    photoset = Photoset.new(site, file_photoset)
    return photoset.gen_html
end