Skip to content

Running filters consecutively #9814

Answered by tarleb
avidseeker asked this question in Q&A
Discussion options

You must be logged in to vote

Both filters explicitly call os.exit(0), i.e., they cause pandoc to terminate. That means that those filters cannot be used in combination like that. You can think of them as custom writers. In fact, with today's pandoc capabilities, it would be conceptually cleaner to rewrite them as writers.

However, the word-count filter has a way to allow further processing by setting:

metadata:
  wordcount: process-anyway

With that you can switch the filter order to ['wc.lua', 'spell.lua'] and then have both filters run consecutively.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by avidseeker
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants