Sha256: 1b9c630334422abba4c6caae05435946986f36f7395efa991e86f6beb50b9cad
Contents?: true
Size: 451 Bytes
Versions: 2
Compression:
Stored size: 451 Bytes
Contents
#!/usr/bin/env ruby require "pandoc_object_filters" incomment = false PandocObjectFilters.filter! do |element| if element.is_a?(PandocObjectFilters::Element::RawBlock) if element.format == "html" if /<!-- BEGIN COMMENT -->/.match(element.value) incomment = true next [] elsif /<!-- END COMMENT -->/.match(element.value) incomment = false next [] end end end next [] if incomment end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
pandoc_object_filters-0.2.0 | examples/comments.rb |
pandoc_object_filters-0.1.0 | examples/comments.rb |