class Middleman::Blog::BlogTemplateProcessor

A special template processor that validates date fields and has an extra- permissive default regex.

@see github.com/sporkmonger/addressable/blob/master/lib/addressable/template.rb#L279

Public Class Methods

match(name) click to toggle source
# File lib/middleman-blog/uri_templates.rb, line 116
def self.match(name)
  case name
  when 'year' then '\d{4}'
  when 'month' then '\d{2}'
  when 'day' then '\d{2}'
  else '.*?'
  end
end