Make Pandoc file conversion faster
You can try to find out why Pandoc conversion is slow by appending
--trace to the command. For instance:
$ pandoc file.md -o file.pdf --trace
will print verbose of the parsing process, paragraph by paragraph, roughly.
Now, if you monitor the parsing process and notice that parsing pauses as it displays the verbose of parsing the paragraph that is on line 24, as shown there:
[trace] Parsed [Para [Str "It",Space,Str "is",Space,Str "easier",Space,Str at line 24
it is possible that Pandoc is having a hard time parsing the paragraph which comes right after, i.e. paragraph 25.
To improve the speed of the parsing process, open the file and find what is slowing down parsing right after the paragraph line 24; a missing square bracket for example.
You can open the file directly on line 24 by running:
$ vi file.md +24
You can also use the utility
time to display the time it took to execute the command. For example:
$ time pandoc file.md -o file.pdf --trace
To learn more about Pandoc, run:
$ man pandoc