Module: Codnar::Configuration::Documentation
- Included in:
- Codnar::Configuration
- Defined in:
- lib/codnar/configuration/documentation.rb
Overview
Configurations for “splitting” documentation files.
Constant Summary collapse
- SPLIT_HTML_DOCUMENTATION =
“Split” a documentation file. All lines are assumed to have the same kind
docand no indentation is collected. Unless overriden by additional configuration(s), the lines are assumed to contain formatted HTML, and are passed as-is to the output.This is the default configuration as it performs the minimal amount of processing on the input. It isn’t the most useful configuration.
{ "formatters" => { "doc" => "Formatter.cast_lines(lines, 'html')", }, "syntax" => { "patterns" => { "doc" => { "regexp" => "^(.*)$", "groups" => [ "payload" ] }, }, "states" => { "start" => { "transitions" => [ { "pattern" => "doc" } ] }, }, }, }
- SPLIT_PRE_DOCUMENTATION =
“Split” a documentation file containing arbitrary text, which is preserved by escaping it and wrapping it in an HTML pre element.
SPLIT_HTML_DOCUMENTATION.deep_merge( "formatters" => { "doc" => "Formatter.lines_to_pre_html(lines, :class => :doc)", } )
- SPLIT_RDOC_DOCUMENTATION =
“Split” a documentation file containing pure RDoc documentation.
SPLIT_HTML_DOCUMENTATION.deep_merge( "formatters" => { "doc" => "Formatter.markup_lines_to_html(lines, Codnar::RDoc, 'rdoc')", "unindented_html" => "Formatter.unindented_lines_to_html(lines)", } )
- SPLIT_MARKDOWN_DOCUMENTATION =
“Split” a documentation file containing pure Markdown documentation.
SPLIT_HTML_DOCUMENTATION.deep_merge( "formatters" => { "doc" => "Formatter.markup_lines_to_html(lines, Codnar::Markdown, 'markdown')", "unindented_html" => "Formatter.unindented_lines_to_html(lines)", } )
- SPLIT_GRAPHVIZ_DOCUMENTATION =
“Split” a documentation file containing a GraphViz diagram.
SPLIT_HTML_DOCUMENTATION.deep_merge( "formatters" => { "doc" => "Formatter.markup_lines_to_html(lines, Codnar::GraphViz, 'graphviz')", "unindented_html" => "Formatter.unindented_lines_to_html(lines)", } )