Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Made it possible to pass multiple files to pandoc - fixes #248 #259

Merged
merged 1 commit into from
Mar 22, 2022

Conversation

JessicaTegner
Copy link
Owner

This pr makes it possible to pass multiple files to pandoc in various ways.

Examples (from the updated readme)

import pypandoc

# convert all markdown files in a chapters/ subdirectory.
pypandoc.convert_file('chapters/*.md', 'docx', outputfile="somefile.docx")

# convert all markdown files in the book1 and book2 directories.
pypandoc.convert_file(['book1/*.md', 'book2/*.md'], 'docx', outputfile="somefile.docx")

# convert the front from another drive, and all markdown files in the chapter directory.
pypandoc.convert_file(['D:/book_front.md', 'book2/*.md'], 'docx', outputfile="somefile.docx")

This fixes #248

simonv3

@simonv3
Copy link

simonv3 commented Mar 21, 2022

This looks like it should do what I want it to, thanks @NicklasTegner

tests.py Show resolved Hide resolved
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Possible to pass multiple files to convert_file
3 participants