Skip to content

Latest commit

 

History

History
53 lines (38 loc) · 1.26 KB

README.org

File metadata and controls

53 lines (38 loc) · 1.26 KB

Lordown

Convert Markdown (CommonMark) to Lorcode markup using Pandoc. Supports CommonMark with some additions:

  • headers of any level are converted to [strong]text[/strong];
  • use SO mention/notify syntax @maxcom to produce [user]maxcom[/user].

Installation

You should have Stack installed.

# Cloning the repo
git clone https://github.com/smaximov/lordown.git
cd lordown
# Setup Stack project
stack setup
# Build
stack build
# Install lorcode binary to ~/.local/bin (use --local-bin-path to specify target directory)
stack install

Usage

lordown provides both a library and an executable.

Executable

lordown -h:

lordown v0.1.1.0 - Markdown to Lorcode converter
Reads Markdown from standard input and writes converted markup to standard output

Usage: lordown

Options:
  -h  --help     Show this message
  -v  --version  Display version

As a library

import Text.Pandoc.Lordown (convert)

main :: IO ()
main = interact convert