MARKDOWN(1)

NAME
markdown - convert Markdown text to HTML

SYNOPSIS
markdown [ -dTV ] [ -b url-base ] [ -F bitmap ] [ -f flags ] [ -o ofile ] [ -s text ] [ -t text ] [ file ]

DESCRIPTION
The markdown utility reads the Markdown(6)-formatted file (or standard input) and writes its HTML fragment representation on standard output.

The options are:

-b url-base
    Links in source begining with / will be prefixed with url-base in the output.

-d  Instead of printing an HTML fragment, print a parse tree.

-F bitmap
    Set translation flags. Bitmap is a bit map of the various configuration options described in markdown(2).

-f flags
    Set or clear various translation flags, described below. Flags are in a comma-delimited list, with an optional + (set) prefix on each flag.

-o ofile
    Write the generated HTML to ofile.

-s text
    Use the markdown(2) function to format the text on standard input.

-T  Under -f toc, print the table of contents as an unordered list before the usual HTML output.

-t text
    Use mkd_text (in markdown(2)) to format text instead of processing standard input with markdown.

-V  Show version number and configuration. If the version includes the string DL_TAG, markdown was configured with definition list support. If the version includes the string HEADER, markdown was configured to support pandoc header blocks.

  TRANSLATION FLAGS
The translation flags understood by -f are:

noimage
    Don't allow image tags.

nolinks
    Don't allow links.

nohtml
    Don't allow any embedded HTML.

cdata
    Generate valid XML output.

noheader
    Do not process pandoc headers.

notables
    Do not process the syntax extension for tables.

tabstops
    Use Markdown-standard 4-space tabstops.

strict
    Disable superscript and relaxed emphasis.

relax
    Enable superscript and relaxed emphasis (the default).

toc Enable table of contents support, generated from headings (in markdown(6)) in the source.

1.0 Revert to Markdown 1.0 compatibility.

For example, -f nolinks,quot tells markdown not to allow <a> tags, and to expand double quotes.

SOURCE
/sys/src/cmd/discount

SEE ALSO
markdown(2), markdown(6)

http://daringfireball.net/projects/markdown/, ``Markdown''.

DIAGNOSTICS
Markdown exits 0 on success and >0 if an error occurs.