Skip to content

unimarkup/unimarkup-rs

Repository files navigation

unimarkup-rs Unimarkup Status

Compiler implementation for the Unimarkup markup language.

Usage

  • Command line tool

    The unimarkup compiler is available as command line tool. Because the compiler is written in Rust, it is possible to install the compiler using the Rust toolchain. Once you have installed the toolchain, unimarkup can be insalled using

    cargo install unimarkup
    

    To convert *.um files to supported output formats, you may run unimarkup --help to see all options. Below are some examples for most common use cases.

    Convert to HTML:

    unimarkup --formats=html my_file.um
    

    Note: If no format is set, the file is converted to all supported formats.

    Define natural language of the content:

    unimarkup --lang=en-US my_file.um
    

    Define output filename:

    unimarkup --output-file=my_output_file my_file.um
    

    Note: If this setting is not set, the output filename is taken from the input filename.

  • Library

    The reference implementation is built with the intent to allow others to build applications on top of it. Therefore, all libraries are bundled inside the unimarkup-core crate. For more information, checkout the core documentation.

Repository structure

This repository is split into several crates:

  • unimarkup ... This crate is located under /cli, and is a CLI wrapper over core
  • unimarkup-commons ... This crate contains common functionalities needed in other Unimarkup crates
  • unimarkup-core ... This crate wraps all Unimarkup library crates, offering a single dependency point for crates building on top of unimarkup-rs
  • unimarkup-inline ... This crate contains the parser for inline elements
  • unimarkup-render ... This crate contains traits and implementations to render Unimarkup content to supported output formats
  • unimarkup-parser ... This crate contains the parser for Unimarkup elements except inlines

License

Apache 2.0 Licensed