davidgranstrom / nvim-markdown-preview

Markdown preview for neovim using pandoc and live-server
GNU General Public License v3.0
105 stars 16 forks source link

Configurable pandoc command / arguments #9

Open languitar opened 2 years ago

languitar commented 2 years ago

I've seen that with #3 some arguments were added to the pandoc command line. In my case, I'd like to include different arguments to render citations using citeproc. So maybe it would be a good idea to make at least some parts of the pandoc command line configurable.

davidgranstrom commented 2 years ago

@languitar Sounds like a good idea! Do you have a concrete example of how your (pandoc) arguments look? It would make it easier to recognise what changes are needed to support your case.

languitar commented 2 years ago

In my case I would have called something like:

$ pandoc 20201005224354.md --from markdown+yaml_metadata_block -s --bibliography ~/Nextcloud/notes/zotero.json --citeproc -o /tmp/out.html
davidgranstrom commented 2 years ago

Thank you for the example! Yes, I agree that there should be a way to pass arbitrary arguments (to pandoc). Maybe something like g:nvim_markdown_preview_pandoc_args = [] that specifies a list of additional arguments?

languitar commented 2 years ago

Sounds good. The only question is how the pandoc binary and the source file are spliced into this?