The stog_markdown plugin allows using Markdown syntax in Stog documents, by converting this syntax to XHTML, using the Omd library or by calling an external command.

Usage:

$ stog --package stog_markdown ...

The first version of this plugin was contributed by Gabriel Scherer.

This plugin adds a new base rule markdown.

## A typical markdown example [Markdown](http://daringfireball.net/projects/markdown/) is a markup language meant to be written simply in a text editor, with a markup that is both easy to read and write. It is later translated into HTML by one of the numerous `markdown` implementations. ````ocaml let f x = x + 1;; ```` ]]>

The markdown rule converts Markdown syntax to (X)HTML, which is then rewritten by the Stog engine like any other XML. Here is the result, embedded in a box:

The markdown rule handles attributes command and args.

The command attribute is used to specify an external command to run to convert Markdown to (X)HTML. The value of args attribute is added on the command line.

Here is an example of using pandoc command, using args attribute to make it translate our markdown code into XHTML:

## A typical markdown example [Markdown](http://daringfireball.net/projects/markdown/) is a markup language meant to be written simply in a text editor, with a markup that is both easy to read and write. It is later translated into HTML by one of the numerous `markdown` implementations. ````ocaml let f x = x + 1;; ```` ]]>

Here is the result, embedded in a box: