aboutsummaryrefslogtreecommitdiff
path: root/pandoc-lua-engine/pandoc-lua-engine.cabal
AgeCommit message (Collapse)Author
2023-03-27Bump pandoc-lua-engine to 0.2, depend on latest pandocJohn MacFarlane
2023-03-20Lua: load text module as `pandoc.text`.Albert Krewinkel
This only affects the name in the Lua-internal documentation. It is still possible to load the modules via `require 'text'`, although this is deprecated.
2023-03-18Lua: add pandoc.cli.repl functionAlbert Krewinkel
2023-03-17pandoc-cli: add a Lua REPLAlbert Krewinkel
2023-03-13Switch to hslua-2.3Albert Krewinkel
2023-02-14Lua: add new function pandoc.system.cputime.Albert Krewinkel
The function returns the CPU time consumed by pandoc and can be used to benchmark Lua computations.
2023-02-11Lua: add module `pandoc.json` to handle JSON encodingAlbert Krewinkel
Closes: #8605
2023-02-11Use latest pandoc-lua-marshal release, version 0.2.1.Albert Krewinkel
All major AST elements now have `__tojson` metamethods that return the JSON representation of an element. This allows to JSON-encode these elements with libraries that respect the `__tojson` metamethod, including dkjson.
2023-02-09Bump pandoc-lua-engine to 0.1.1pandoc-lua-engine-0.1.13.1John MacFarlane
2023-02-09pandoc-lua-engine: require pandoc >= 3.1.John MacFarlane
2023-02-08pandoc-lua-engine: relax version bound to allow pandoc 3.1.John MacFarlane
2023-01-15Lua: add module `pandoc.structure`.Albert Krewinkel
Adds support for table of contents and chunks handling. The function `make_sections` has been given a friendlier interface and was moved to the new module; the old `pandoc.utils.make_sections` has been deprecated.
2023-01-13Use latest dev pandoc-lua-marshal.John MacFarlane
2023-01-13Require pandoc-types 1.23, update dependencies.John MacFarlane
This fails to build because pandoc-lua-marshal still needs updating.
2023-01-12CI: test with GHC 9.2.5 and 9.4.4Albert Krewinkel
2023-01-03Lua: add functions `pandoc.text.toencoding`, `pandoc.text.fromencoding`.Albert Krewinkel
Closes: #8512
2022-12-20T.P.Scripting: Refactor the scripting engine.John MacFarlane
The new type CustomComponents is exported from T.P.Scripting, and the ScriptEngine fields are changed. Instead of separate fields for custom readers and writers, we now have a single function that loads any number of "components" from a script: these may be custom readers, custom writers, templates for writers, or extension configs. (Note: it's possible to have a custom reader and a custom writer for a format together in the same file.) Pandoc now checks the folder `custom` in the user's data directory for a matching script if it can't find one in the local directory. Previously, the `readers` and `writers` data directories were search for custom readers and writers, respectively. Scripts in those directories must be moved to the `custom` folder. Custom readers used to implement a fallback behavior that allowed to consume just a string value as input to the `Reader` function. This has been removed, the first argument is now always a list of sources. Use `tostring` on that argument to get a string. Closes #8417. Signed-off-by: Albert Krewinkel <[email protected]>
2022-12-12Lua: add pandoc.cli moduleAlbert Krewinkel
Allow processing of CLI options in Lua.
2022-11-21Use doctemplates 0.11.John MacFarlane
This avoids a transitive dependency on HsYAML, which we no longer use in pandoc.
2022-11-15Allow mtl 2.3.1Alexander Batischev
2022-10-21Lua: add pandoc.scaffolding.Writer (#8377)Albert Krewinkel
This can be used to reduce boilerplate in custom writers.
2022-10-20Lua: add new module `pandoc.zip`Albert Krewinkel
Allows to handle docx and epub files.
2022-10-14Lua: Support built-in default templates for custom writersAlbert Krewinkel
Custom writers can define a default template via a global `Template` function; the data directory is no longer searched for a default template. Writer authors can restore the old lookup behavior with ``` lua Template = function () local template return template.compile(template.default(PANDOC_SCRIPT_FILE)) end ```
2022-10-10Lua: support extensions in custom writersAlbert Krewinkel
Custom writers can define the extensions that they support via the global `writer_extensions`. The variable's value must be a table with all supported extensions as keys, and their default status as values. E.g., the below specifies that the writer support the extensions `smart` and `sourcepos`, but only the `smart` extension is enabled by default: writer_extensions = { smart = true, sourcepos = false, }
2022-10-10Lua: support custom bytestring readers.Albert Krewinkel
2022-10-06Lua: cleanup module dependenciesAlbert Krewinkel
Ensures a cleaner module dependency graph.
2022-10-04Lua: add new module `pandoc.format`.Albert Krewinkel
The module provides functions to query the set of extensions supported by formats, and the set of extension enabled per default.
2022-10-04Lua: ensure that extensions marshaling is consistent.Albert Krewinkel
2022-10-03Add test for custom bytestring writersAlbert Krewinkel
2022-10-03Remove unused lua53 flag.John MacFarlane
2022-10-03Remove support for Lua 5.3.Albert Krewinkel
2022-09-30[API Change] Extract Lua code into new package pandoc-lua-engineAlbert Krewinkel
The flag 'lua53` must now be used with that package if pandoc is to be compiled against Lua 5.3.