Den mån 6 juni 2022 20:39John MacFarlane skrev: > Albert Krewinkel writes: > > > I'm not sure if it's better or worse, but we could also look for the > > reader in LUA_PATH (via `require`). Using a bit of pseudo-code: > > > > if file_exists(reader_path) then > > dofile(reader_path) > > reader = Reader > > else > > reader = require (reader_path:gsub('.lua$', '')) > > end > > > > The reader library would have to `return` the Reader function instead of > > just defining it as a global. > > Probably better not to change the interface in this way. > > Maybe treating these like filters is the most sensible/least > surprising thing to do. IMO the most sensible. That way you can just clone readers/writers off GitHub without authors needing to go through the hassle of setting up a Lua rock. Having to do that will likely discourage people from publishing their code at all. Also of course templates, filters, defaults all work that way already. I have my data dir in my dropbox directory and symlink it in ~/.local/share, or rclone it on my Android devices (via Termux) where dropbox isn't a regular storage directory. Should we have readers/ and writers/ > subdirectories of user data? Or custom-readers/ custom-writers/ ? > Since they are already subdirectories of the dedicated pandoc data directory `readers/` and `writers/` should suffice. Seven characters less to type for each compared to `custom-*`. > -- > 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit > https://groups.google.com/d/msgid/pandoc-discuss/yh480kv8tdd4de.fsf%40johnmacfarlane.net > . > -- 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-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/CADAJKhDdwHuvBjTCAAwrFY6RcaZ%2Bd_FRMnkVp3MMUtntrsBdYg%40mail.gmail.com.