Orc/discount
FreeMy C implementation of John Gruber's Markdown markup language
FreeFree tier
About Orc/discount
DISCOUNT is a C implementation of John Gruber and Aaron Swartz's Markdown markup language. It fully supports the standard Markdown syntax as described by Gruber and passes the official Markdown test suite. The library includes several command-line tools (mkd2html, makepage, theme) and supports extensions for GitHub Flavored Markdown, HTML5 output, XML output, and automatic table of contents generation. It is released under a BSD-style license, allowing free use and modification. The distribution includes manual pages and an INSTALL file for building.
Key Features
Full Markdown syntax support (passes official test suite)
GitHub Flavored Markdown support (tables, fenced code blocks, etc.)
HTML5 and XHTML output
Automatic table of contents generation
Multiple command-line tools: mkd2html, makepage, theme
BSD-style open-source license
C library for embedding in applications
Includes manual pages for all tools
Pros & Cons
Pros
- Lightweight and fast C implementation
- Well-tested against official Markdown test suite
- Flexible output formats (HTML5, XML, XHTML)
- Permissive BSD license allows commercial use without restrictions
- Small footprint, suitable for embedded systems
Cons
- No graphical user interface (command-line only)
- Requires compilation from source (no pre-built binaries)
- Limited to Markdown processing (not a full static site generator)
- Documentation consists primarily of manual pages
Best For
Converting Markdown to HTML in C-based applicationsStatic site generationDocumentation generation from Markdown filesBlogging platforms needing lightweight Markdown parsingEmbedding Markdown rendering in software projects
FAQ
What is DISCOUNT?
DISCOUNT is a C implementation of John Gruber and Aaron Swartz's Markdown markup language, developed by Jessica L. Parsons.
What license does DISCOUNT use?
It is released under a BSD-style license that allows you to do as you wish with it as long as you don't attempt to claim it as your own work.
Does DISCOUNT support GitHub Flavored Markdown?
Yes, it includes github_flavoured.c, which adds support for GitHub Flavored Markdown features such as tables, fenced code blocks, and more.
What output formats are supported?
DISCOUNT can output HTML5, XHTML, XML, and plain text. It also supports generating a table of contents.
How do I build DISCOUNT?
The distribution includes an INSTALL file and a configure.sh script. Use these to build the library and command-line tools on Unix-like systems.