| Age | Commit message (Collapse) | Author |
|
|
|
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.
|
|
|
|
|
|
|
|
The function returns the CPU time consumed by pandoc and can be used to
benchmark Lua computations.
|
|
Closes: #8605
|
|
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.
|
|
|
|
|
|
|
|
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.
|
|
|
|
This fails to build because pandoc-lua-marshal still needs updating.
|
|
|
|
Closes: #8512
|
|
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]>
|
|
Allow processing of CLI options in Lua.
|
|
This avoids a transitive dependency on HsYAML, which we no longer
use in pandoc.
|
|
|
|
This can be used to reduce boilerplate in custom writers.
|
|
Allows to handle docx and epub files.
|
|
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
```
|
|
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,
}
|
|
|
|
Ensures a cleaner module dependency graph.
|
|
The module provides functions to query the set of extensions supported
by formats, and the set of extension enabled per default.
|
|
|
|
|
|
|
|
|
|
The flag 'lua53` must now be used with that package if pandoc is to be
compiled against Lua 5.3.
|