My goal is debugging LUA filters with the zerobrane ide.

I got stuck on this:

On Ubuntu I installed pandoc 2.5 using sudo apt install pandoc.
After that I cloned the lua filter repository (https://github.com/pandoc/lua-filters)
When I run the pandoc commmand like so:

>pandoc --lua-filter=include-files.lua sample.md --output result.html
(
This lua filter requires this:
local List = require 'pandoc.List'
local path = require 'pandoc.path'
local system = require 'pandoc.system'
)

I get this error:
include-files.lua:10: module 'pandoc.path' not found:no file 'pandoc.path.lua' in pandoc's datadir
        no field package.preload['pandoc.path']
        no file '/usr/local/share/lua/5.3/pandoc/path.lua'
        no file '/usr/local/share/lua/5.3/pandoc/path/init.lua'
        no file '/usr/local/lib/lua/5.3/pandoc/path.lua'
        no file '/usr/local/lib/lua/5.3/pandoc/path/init.lua'
        no file './pandoc/path.lua'
        no file './pandoc/path/init.lua'
        no file '/usr/local/lib/lua/5.3/pandoc/path.so'
        no file '/usr/local/lib/lua/5.3/loadall.so'
        no file './pandoc/path.so'
        no file '/usr/local/lib/lua/5.3/pandoc.so'
        no file '/usr/local/lib/lua/5.3/loadall.so'
        no file './pandoc.so'
stack traceback:
        [C]: in function 'require'
        include-files.lua:10: in main chunk

After some research I found that there is a directory /usr/share/pandoc/data.

The contents of this directory contains the lua files:
init.lua  pandoc.List.lua  pandoc.lua  sample.lua

There is no pandoc.path.lua.....

So pandoc is not checking /usr/share/pandoc/data and even if I set LUA_PATH like so:
>export LUA_PATH=/usr/share/?/?.lua
It gives me this error:
Error running filter include-files.lua:
include-files.lua:10: module 'pandoc.path' not found:no file 'pandoc.path.lua' in pandoc's datadir
        no field package.preload['pandoc.path']
        no file '/usr/share/pandoc/path/pandoc/path.lua'
        no file '/usr/local/lib/lua/5.3/pandoc/path.so'
        no file '/usr/local/lib/lua/5.3/loadall.so'
        no file './pandoc/path.so'
        no file '/usr/local/lib/lua/5.3/pandoc.so'
        no file '/usr/local/lib/lua/5.3/loadall.so'
        no file './pandoc.so'
stack traceback:
        [C]: in function 'require'
        include-files.lua:10: in main chunk
 
What am I doing wrong here......
 



--
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/091e1142-2cf5-40f0-a0f4-1c6a2bd0af4bn%40googlegroups.com.