md-to-pdf: bug: Watch mode only works once
Context:
- version (
md-to-pdf -v): 3.2.1 - platform (Unix, macOS, Windows): Windows
- node version: v10.18.0
Describe the bug:
The watch mode only works the first time after it generates an empty PDF.
A clear and concise description of what the bug is. Feel free to include screenshots.
- Create a
documentation.mdfile - Run
md2pdf documentation.md --watch - Open the PDF and see that’s it is generated correctly ✔️
- Make a change to
documentation.md - Open the PDF file and see that’s it is generated correctly ✔️
- Make a change to
documentation.md - Open the PDF file and see that’s the file empty now ❌
- You can repeat step 6 and 7 several time the file will always be empty now ❌

The problem occurs also when adding --as-html.
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 16 (10 by maintainers)
I don’t think I’ll provide a default value here because I can’t even reproduce the issue at all on macOS so it’s probably not even necessary for a good chunk of the users. But thanks for confirming that this fixes it, i’ll see that I make a commit and release this soon.