summaryrefslogtreecommitdiff
path: root/pandoc.cabal
diff options
context:
space:
mode:
authorAlbert Krewinkel <albert+github@zeitkraut.de>2017-11-29 01:20:01 +0100
committerJohn MacFarlane <jgm@berkeley.edu>2017-11-28 17:20:01 -0700
commit0105a3c2930675971ea83da3b987c6b62f97ce26 (patch)
tree16221c1f6e610118a721f5b072464a9c48adb161 /pandoc.cabal
parent5a225aa6037621209d41927e24d682389d719f50 (diff)
Add basic lua List module (#4099)
The List module is automatically loaded, but not assigned to a global variable. It can be included in filters by calling `List = require 'List'`. Lists of blocks, lists of inlines, and lists of classes are now given `List` as a metatable, making working with them more convenient. E.g., it is now possible to concatenate lists of inlines using Lua's concatenation operator `..` (requires at least one of the operants to have `List` as a metatable): function Emph (emph) local s = {pandoc.Space(), pandoc.Str 'emphasized'} return pandoc.Span(emph.content .. s) end Closes: #4081
Diffstat (limited to 'pandoc.cabal')
-rw-r--r--pandoc.cabal2
1 files changed, 2 insertions, 0 deletions
diff --git a/pandoc.cabal b/pandoc.cabal
index cab2bba23..26af5bcbc 100644
--- a/pandoc.cabal
+++ b/pandoc.cabal
@@ -110,6 +110,8 @@ data-files:
data/sample.lua
-- pandoc lua module
data/pandoc.lua
+ -- lua List module
+ data/List.lua
-- sample highlighting theme
data/default.theme
-- bash completion template