Open marwie opened 4 years ago
Hi @marwie this isn't something we support at the moment. What sort of use case do you have, and what kind of results do you expect?
Hi @BlueHatbRit,
agree that using mpdf to convert a folder/subfolder structure to PDF would be a great enhancement. The use case is about all the GitBook / Wiki structures out there:
Some examples: https://github.com/Netflix/Hystrix/wiki https://github.com/d3/d3/wiki https://docs.gitbook.com/
All of these are using a file called _Sidebar.md to structure the documentation and mdpdf could use such a file to generate one PDF from any wiki or gitbook repository.
Thanks, Christian
Hi @cekageka thanks for the examples there. This certainly is an interesting idea and I'm not against it existing in mdpdf generally speaking. That said I have a couple of concerns which we'd need to think about an address before merging anything in.
_Sidebar.md
is interesting to structure things, although I'd worry that it would be quite brittle to parse as it's just a markdown file. Golum and gitbooks seem to use it but there would be a reasonable amount of work around building something to parse those files and ensure they're valid.If we could solve those to a good degree, I think I'd be ok with a new command or sub-command going in to handle this kind of thing.
Right now it's not something I'm keen to work on personally but if someone else wanted to have a crack I'd be happy to give some advice on a potential implementation.
Hi @BlueHatbRit,
thanks for your very fast reply. I totally agree - after thinking twice I assume it's already perfectly possible to use mdpdf similar to the following pandoc script to do the job:
https://gist.github.com/clemsos/9e480b2b792b57f1b22d
So from my perspective the issue is solved.
Thanks again, Christian
Hello,
great tool! Would it be possible to add support for merging multiple files into one pdf? Or is it already possible?
Kind regards, Marcel