Pancake

Toolkit for writing Lua filters for Pandoc. It is lightweight-ish, documented, and tested.

Pancake aides with:

  • maintaining compatibility accross different versions of Pandoc
  • working with complex data structures
  • error handling
  • string interpolation
  • object-oriented programming
  • file I/O and filesystem interaction
  • metadata parsing (i.e., configuration)

See its documentation for details.

Requirements

Pancake requires Pandoc ≥ v2.0.4. It should work under every operating system supported by Pandoc.

It has been tested with Pandoc v2.9–v2.18 on Debian GNU/Linux and macOS.

Your version of Pandoc must also support Lua ≥ v5.3. Pandoc ≥ v2 does so by default. However, the Pandoc package provided by your operating system vendor may use an older version. Notably, the version of Pandoc available in the package repository of Debian v10 (“Buster”) only supports Lua v5.1.

Installation

You use Pancake at your own risk.

  1. Download the latest release.
  2. Unpack it.
  3. Move pancake.lua someplace where your filter can load it from.

If LuaRocks is installed on your system, you can simply asy:

luarocks install pancake

The most recent release is v1.0.0b18.

Documentation

See the source code documentation, and the source code itself for details.

Contact

If there’s something wrong with Pancake, please open an issue.

Testing

The test suite requires:

  1. A POSIX-compliant operating system.
  2. Pandoc ≥ v2.
  3. LuaUnit.
  4. GNU Make.

Simply say:

    make

License

Copyright 2018–2022 Odin Kroeger

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Further Information

GitHub: https://github.com/odkr/pancake

generated by LDoc 1.4.6 Last updated 2022-04-15 19:08:25