Giter Site home page Giter Site logo

mmarkdown / mmark Goto Github PK

View Code? Open in Web Editor NEW
479.0 7.0 48.0 1.03 MB

Mmark: a powerful markdown processor in Go geared towards the IETF

Home Page: https://mmark.miek.nl

License: Other

Go 74.90% Makefile 1.24% Roff 23.86%
markdown mmark go ietf xml html5 nroff xml2rfc

mmark's Introduction

title date aliases
About
2018-07-22 14:05:51 +0100
/about/

Mmark is a powerful markdown processor written in Go, geared towards writing IETF documents. It is, however, also suited for writing complete books and other technical documentation, like the Learning Go book (mmark source, and I-D text output).

Also see this repository on how to write RFC using Markdown.

It provides an advanced markdown dialect that processes file(s) to produce internet-drafts in XML RFC 7991 format. Mmark can produce xml2rfc (aforementioned RFC 7991), HTML5 output, and manual pages.

Example RFCs in Mmark format can be found in the Github repository.

Mmark uses gomarkdown which is a fork of blackfriday. See its README.md for more documentation.

Syntax

Mmark's syntax and the extra features compared to plain Markdown are detailed in syntax.md.

Mmark adds the following syntax elements to gomarkdown/markdown:

Usage

You can download a binary or optionally build mmark your self. You'll need a working Go environment, then check out the code and:

% go get && go build
% ./mmark -version
2.0.0

To output XML2RFC v3 xml just give it a markdown file and:

% ./mmark rfc/3514.md

Making a draft in text form (v3 output)

% ./mmark rfc/3514.md > x.xml
% xml2rfc --v3 --text x.xml

Outputting HTML5 is done with the -html switch.

Files edited under Windows/Mac and using Windows style will be converted into Unix style line ending before parsing. Any output from mmark will use Unix line endings.

Note there are no wrong markdown documents, so mmark will only warn about things that are not right. This may result in invalid XML. Any warning from mmark are send to standard error, to see and check for those you can discard standard output to just leave standard error: ./mmark rfc/3515.md > /dev/null.

Example RFC

The rfc/ directory contains a couple of example RFCs that can be build via v3 tool chain. The build the text files, just run:

cd rfc
make txt

Official RFCs are in rfc/orig (so you can compare the text output from mmark).

Also See

Kramdown-rfc2629 is another tool to process markdown and output XML2RFC XML.

See Syntax.md for a primer on how to use the Markdown syntax to create IETF documents.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.