Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Parsing markdown (pandoc or other tools?) #30

Open
pietroppeter opened this issue May 4, 2020 · 3 comments
Open

Parsing markdown (pandoc or other tools?) #30

pietroppeter opened this issue May 4, 2020 · 3 comments

Comments

@pietroppeter
Copy link

In order to do finalize a translation we will need to parse the markdown in words.md into html. I was expecting that pandoc would work out of the box but apparently this is not the case. I was able to get what appears to be a good parsing (with footnotes) using the following:

 pandoc --from markdown_strict+footnotes words\words.md -o words\words.html

This was supposed to work but did not work for me.

pandoc --from markdown-markdown_in_html_blocks+raw_html words\words.md -o words\words.html

For the above recipes see discussion here: https://stackoverflow.com/questions/39220389/embed-indented-html-in-markdown-with-pandoc

In order for the above to work correctly I had also to substitute . . . with <p>. . .</p> in words.md.

Are there any better solutions out there? Would be worthwhile adding something like this to the how-to-translate instructions?

Awesome work btw!

@vrruiz
Copy link

vrruiz commented May 4, 2020

I'm using MacDown in Mac and I export from there. Ghostwriter in Linux doesn't support footnotes.

@pietroppeter
Copy link
Author

We added to our Italian translation (#3) repo, a build command that streamlines the update of index.html (it calls pandoc with appropriate parameters and manages automatically the cut and paste inside article). It seems to be working fine.

Since it might be useful for other, you find it here with discussion on how to use it here.

@harisont
Copy link
Contributor

harisont commented May 5, 2020

I would like to add a tip: if you install pandoc (especially if just for this project, but once you install it you will probably want to have it forever anyway), just get the binaries. Compiling it requires an unreasonable amount of dependencies (and time).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants