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

Improve markup processing #19

Closed
5 tasks done
jdkato opened this issue Mar 2, 2017 · 1 comment
Closed
5 tasks done

Improve markup processing #19

jdkato opened this issue Mar 2, 2017 · 1 comment

Comments

@jdkato
Copy link
Member

jdkato commented Mar 2, 2017

@jdkato jdkato changed the title Move markup processing to its own repo Improve markup processing Mar 6, 2017
jdkato added a commit that referenced this issue Mar 6, 2017
This replaces the temporary solution of trying to parse the Markdown
ourselves.

Related to #19
@jdkato
Copy link
Member Author

jdkato commented Mar 8, 2017

I think the best strategy for reStructuredText, AsciiDoc and LaTeX is to rely on external programs (such as rst2html and Asciidoctor) to convert them into HTML. We can then use the net/html package to get what we need.

This obviously goes against the goal of being standalone, but it's the only realistic option for accurately targeting specific scopes (e.g., ignoring code spans and URLs or assigning certain rules to headings). I also think it's reasonable to assume that users of these formats will already have the required programs installed (for instance, rst2html comes with both docutils and Sphinx), and we should be able to get their location using exec.LookPath.

(For what it's worth, Hugo uses the same technique.)

@jdkato jdkato closed this as completed Mar 13, 2017
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

1 participant