class Nanoc::DataSources::Filesystem::Parser
Public Instance Methods
parse_metadata(data, filename)
click to toggle source
There are a lot of problems when trying to parse liquid out of the frontmatter—all of them dealing with collision between the { character in Liquid and its signfigance in YAML. We'll overload the parse method here to resolve those issues ahead of time.
# File lib/nanoc-conref-fs/conref-fs.rb, line 11 def parse_metadata(data, filename) wrapped_data = data.gsub(/^([^:]+): (\{\{.+)/, '\1: \'\2\'') old_parse_metadata(wrapped_data, filename) end
Also aliased as: old_parse_metadata