The `type` field must be `lua` or `json` depending on whether the filter is a Lua or JSON filter[^1]. The name of the filter, complete with extension, and possibly preceded by the file system path, goes into the `path` field. If the filter is a Lua filter and has a `.lua` extension or is a JSON filter and does not have a `.lua` extension (since in principle JSON filters can be written in Lua!) you can just give a string with the file name (or full/relative path) as the list item value, so

``````yaml
filters:
  - myluafilter.lua
  - myjsonfilter.py
``````

is equivalent to

``````yaml
filters:
  - type: lua
    path: myluafilter.lua
  - type: json
    path: myjsonfilter.py
``````

[^1]: https://pandoc.org/filters.html

--
Better --help|less than helpless

Den lör 20 mars 2021 11:41Илья Волк <thesun409-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> skrev:
---
filters: 
- type: pandoc-plot              *not working
---
filters:
- {type: pandoc-plot}          *not working
---
filters:
- pandoc-plot                      *not working
---
pandoc-plot: true              *not working
---
filters:
- path: /usr/bin/pandoc-plot  *not working
---

What i do wrong? 
суббота, 20 марта 2021 г. в 13:10:29 UTC+3, BP:
You have to use a defaults file, *not* document metadata, and you have to use this format (note that it is `filters:` — *not* `filter:` and the value is a list!)

# Filters will be assumed to be Lua filters if they have
# the .lua extension, and json filters otherwise.  But
# the filter type can also be specified explicitly, as shown.
# Filters are run in the order specified.
# To include the built-in citeproc filter, use either `citeproc`
# or `{type: citeproc}`.
filters:
- wordcount.lua
- type: json
  path: foo.lua

See: 


--
Better --help|less than helpless

Den fre 19 mars 2021 22:47Илья Волк <thes...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> skrev:
Have the same issue. I want to specified filter pandoc-plot in YAML but it does not work( (it works well by calling --filter=pandoc-plot works well

вторник, 16 марта 2021 г. в 16:32:39 UTC+3, Julien Dutant:
Doesn't look like there is: using the "filters" field works in defaults yaml files but not in the document own's yaml block. So it looks like having a defaults file next to your source file is your best bet.

J
On Sunday, March 14, 2021 at 1:02:40 PM UTC denis...-FfwAq0itz3ofv37vnLkPlQ@public.gmane.org wrote:
I don't know about document metadata, but you might want to look into "defaults files".

Denis



________________________________________
Von: pandoc-...@googlegroups.com <pandoc-...@googlegroups.com> im Auftrag von First User <firstu...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Gesendet: Sonntag, 14. März 2021 13:13:48
An: pandoc-discuss
Betreff: Specify pandoc filters in the meta data file ?

Is there any field to specify the filters like pandoc-crossref, pandoc-include, etc I would like to use to process the file ? Something like
---
filters:
- pandoc-crossref
- pandoc-include
...
---

instead of having to run --filter=pandoc-crossref at the command line every time ?

--
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-discus...@googlegroups.com<mailto:pandoc-discus...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/de2d17dc-c718-460f-9bcd-099ff415337cn%40googlegroups.com<https://groups.google.com/d/msgid/pandoc-discuss/de2d17dc-c718-460f-9bcd-099ff415337cn%40googlegroups.com?utm_medium=email&utm_source=footer>.

--
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-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/c63e8671-3542-4354-90b8-e78c290596fcn%40googlegroups.com.

--
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-/JYPxA39Uh4Ykp1iOSErHA@public.gmane.orgm.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/6cfac466-2c08-4155-ab0b-3dac50c0180bn%40googlegroups.com.

--
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/CADAJKhAT65TmhFrobMCCePzXrA_ajVUakEmYcB_t%3D6VH6%2B6YMw%40mail.gmail.com.