I'm using the following command line to generate a *.pdf file from my *.md file:
pandoc --pdf-engine=xelatex file.md -o file.pdf
Everything works fine except when I copy-paste a code block from the generated *.pdf. It then loses its spaces/tabs and so the following if statement:
if (i<j)
{
i=i+5;
}
becomes
if (i<j)
{
i=i+5;
}
Is there anyway around this?
if (i<j) { i=i+5; }in a single line. Having to guess what really you could be doing does not help. – Fran Dec 25 '19 at 20:34