Posodobitev pandoc filtrov

master
urosm 2024-10-06 16:41:00 +02:00
parent 050511efac
commit 4e797c8ddc
2 changed files with 12 additions and 1 deletions

View File

@ -0,0 +1,10 @@
SCRIPT_NAME = "inline_lua.lua"
os.setlocale("C")
return {
{ CodeBlock = function(el)
if el.classes[1] == "lua" and el.classes[2] == "inline" then
return load(el.text)()
end
end }
}

View File

@ -10,7 +10,8 @@ return {
local f = io.open(fp)
if f == nil then
print(("[WARNING] Broken link: %s"):format(l.target)) -- TODO: update for pandoc.info
local input_file = PANDOC_STATE.input_files[1]
print(("[WARNING] Broken link: %s -> %s"):format(input_file, l.target)) -- TODO: update for pandoc.info
return l.content
end
f:close()