That would work except for the fact that a JSON filter *could* be written in Lua and there probably are such filters out there. I thought there used to be an -L option but I can't find it anymore so perhaps -L can be repurposed as a synonym of --lua-filter. (Which reminds me I ought to update my default-options wrapper script to reflect the current set of options!) Den tors 5 sep. 2019 22:46Joseph Reagle skrev: > > On 9/5/19 3:55 PM, BPJ wrote: > > https://github.com/pandoc/lua-filters/tree/master/pagebreak > > Thank you, that requires me to add `\newpage` to my files (rather than as > an option on input file processing) but that's easy enough. And when I > don't use the filter, it looks like the latex command is ignored. > > Two asides: > > 1. For lua filters, why not use the same `-F`/`--filters` option? > > I know lua is internal and the other is json-based, but couldn't pandoc > figure it out? > > 2. When I accidentally used `--filter`, I get a confusing message: > > ``` > ╰─➤ pandoc --filter=pagebreak.lua --toc -i 1-chap.md 2-chap.md -s -o > test.docx > Error running filter /Users/reagle/.pandoc/filters/pagebreak.lua: > Could not find executable /Users/reagle/.pandoc/filters/pagebreak.lua > ``` > > It is there, it'd be nicer if it said "if a lua file, use --lua-filter." > > -- > 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/16c406f5-ca1a-c2f2-de16-db846a919570%40reagle.org > . > -- 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/CAFC_yuTGVSn9VaG4h3-NgngzKxOW0maTvcpnxakUx7oTYYEjWw%40mail.gmail.com.