• Stars
    star
    306
  • Rank 136,456 (Top 3 %)
  • Language
    C
  • License
    Other
  • Created over 11 years ago
  • Updated about 9 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

This project is now deprecated. Please use MultiMarkdown-6 instead!

Title: MultiMarkdown 4 ReadMe
Author: Fletcher T. Penney
Base Header Level: 2

Introduction

Markdown is a simple markup language used to convert plain text into HTML.

MultiMarkdown is a derivative of Markdown that adds new syntax features, such as footnotes, tables, and metadata. Additionally, it offers mechanisms to convert plain text into LaTeX in addition to HTML.

Background

MultiMarkdown started as a Perl script, which was modified from the original Markdown.pl.

MultiMarkdown v3 (aka 'peg-multimarkdown') was based on John MacFarlane's peg-markdown. It used a parsing expression grammar (PEG), and was written in C in order to compile on almost any operating system. Thanks to work by Daniel Jalkut, MMD v3 was built so that it didn't have any external library requirements.

MultiMarkdown v4 is basically a complete rewrite of v3. It uses the same basic PEG for parsing (Multi)Markdown text, but otherwise is almost completely rebuilt:

  • The code is designed to be easier to maintain --- it's divided into separate files on a more logical structure
  • All memory leaks (to my knowledge) have been fixed
  • greg is used instead of peg/leg to create the parser --- this allows the parser to be thread-safe
  • The test suite has been modified to account for several improvements. MMD should fail one of the basic Markdown tests (see peg-markdown for more information).
  • Command line options are slightly different.

Installation

You can compile for yourself, or download a precompiled binary from the downloads page.

  • Download the source from the github web site using git
  • git submodule init and then git submodule update to download greg and the test suite
  • Run make to compile.
  • Run make test-all | less to verify that the build is correct. As mentioned, one of the tests is expected to fail; the rest should pass on all systems.
  • Run sudo make install and (optionally) sudo make install-scripts to install multimarkdown and the helper scripts.

Usage

Once installed, you simply do something like the following:

  • multimarkdown file.txt --- process text into HTML.

  • multimarkdown -c file.txt --- use a compatibility mode that emulates the original Markdown.

  • multimarkdown -t latex file.txt --- output the results as LaTeX instead of HTML. This can then be processed into a PDF if you have LaTeX installed. You can further specify the LaTeX Mode metadata to customize output for compatibility with memoir or beamer classes.

  • multimarkdown -t odf file.txt --- output the results as an OpenDocument Text Flat XML file. Does require the plugin be installed in your copy of OpenOffice, which is available at the peg-multimarkdown-downloads page. LibreOffice includes this plugin by default.

  • multimarkdown -t opml file.txt --- convert the MMD text file to an MMD OPML file, compatible with OmniOutliner and certain other outlining and mind-mapping programs (including iThoughts and iThoughtsHD).

  • multimarkdown -h --- display help and additional options.

  • multimarkdown -b *.txt --- -b or --batch mode can process multiple files at once, converting file.txt to file.html or file.tex as directed. Using this feature, you can convert a directory of MultiMarkdown text files into HTML files, or LaTeX files with a single command without having to specify the output files manually. CAUTION: This will overwrite existing files with the html or tex extension, so use with caution.

Notes

If you get an error that greg fails to build try touch greg/greg.c. I had an issue where the timestamp on that file might have been too old, which caused the build to fail.

LyX Support

Charles R. Cowan (https://github.com/crcowan) added support for conversion to LyX. Support for this should be considered to be in alpha/beta, and is not guaranteed. Issues related to LyX can be added to the MultiMarkdown issues page on github, but will need to be answered by Charles. I am happy to include this code in the main MMD repo, but since I don't use LyX I can't support it myself. If this arrangement becomes a problem, then LyX support can be removed and it can be kept as a separate fork.

More Information

To get more information about MultiMarkdown, check out the website or User's Guide.

More Repositories

1

MultiMarkdown

Expanded perl version of John Gruber's original Markdown --- No longer under active development since MMD 3
Perl
1,065
star
2

MultiMarkdown-6

Lightweight markup processor to produce HTML, LaTeX, and more.
C
616
star
3

MultiMarkdown-5

Reference implementation of MultiMarkdown; replaces MultiMarkdown v4 (deprecated -- see MMD-6 instead)
C
293
star
4

peg-multimarkdown-latex-support

Default support files for generating LaTeX documents with MMD 3 through MMD 5
TeX
120
star
5

MultiMarkdown-Gallery

A collection of example MMD files demonstrating different features
TeX
118
star
6

MMD-QuickLook

Improved QuickLook generator for MultiMarkdown files (FYI, the closed-source version from http://multimarkdown.com/ is better and also free.)
C
96
star
7

MultiMarkdown-CMS

Package to assist with publishing a web site using MMD and a few perl scripts
Perl
95
star
8

Markdown.ooxsl

Markdown export plugin for OmniOutliner
XSLT
87
star
9

c-template

Boilerplate to set up a c project, include CuTest unit testing, cmake build setup
C
78
star
10

c-sss

Implementation of Shamir's Secret Sharing in C
C
63
star
11

SimplenoteSync

perl routine to sync folder of text files with your notes on Simplenote
Perl
58
star
12

MMD-Support

Various utility files to expand the features of MultiMarkdown 3.0
XML
40
star
13

MultiMarkdown-6-Syntax-Guide

Quick syntax guide for MultiMarkdown v6 -- click the link to the right!
HTML
36
star
14

MMD-Edit

Syntax-highlighting text editor for MultiMarkdown, based on work by Ali Rantakari
Objective-C
33
star
15

MMD-Test-Suite

Set of test documents to verify that MMD 4 is working properly
HTML
28
star
16

MMD-ePub

Now deprecated -- MMD v6 has better (and easier) support for exporting EPUB v3
XSLT
20
star
17

magnum

C implementation of Mustache "logic-less templates" (http://mustache.github.io/)
C
14
star
18

tdp

Convert tabular data (CSV, TSV) into JSON
C
10
star
19

MMD-Users-Guide

Source documents for the MultiMarkdown User's Guide (v2.0 aka Perl version)
8
star
20

MMD-6-QuickLook

macOS QuickLook Generator using MMD v6
C
8
star
21

MultiMarkdown-Composer-Themes

Themes for MultiMarkdown Composer v 3 (They should basically work on v 2 as well.)
8
star
22

html-email-builder

Workflow to build responsive HTML email via MultiMarkdown (and optionally upload to sendinblue.com)
CSS
5
star
23

MMD-Composer-2-Wiki

Wiki to generate User's Guide for MultiMarkdown Composer 2.0
4
star
24

c-boilermaker

Boilerplate C project template using CMake, CuTest and more, to simplify creating new projects. Successor to my older c-template boilerplate.
C
3
star
25

vagrant-mmd-cms

Configuration file for Vagrant to generate virtual server for MultiMarkdown-CMS hosted web site
Shell
3
star
26

MMD-Composer-4-Expansions

Example text expansions for Pro version of MultiMarkdown Composer 4
2
star
27

ios-cmake

Automatically exported from code.google.com/p/ios-cmake
CMake
2
star
28

Composer-5-Support-Files

Themes compatible with MultiMarkdown Composer 5 and nvUltra
CSS
2
star
29

Composer-Localization

String files for localizing the MultiMarkdown Composer application
1
star
30

core-utilities

Central repository for a few core libraries I reuse across many of my projects
C
1
star
31

text-parser-template

Boilerplate text parsing example using re2c lexer and lemon parser.
C
1
star
32

cmake-test-app

Objective-C
1
star
33

FTPLibFuzzer

Configuration files to build a vagrant machine with development tools for fuzz testing my software
C
1
star
34

c-title-case

C implementation of John Gruber's title case Perl script
C
1
star