houseabsolute / Markdent

An event-based Markdown parser toolkit
http://metacpan.org/release/Markdent/
Other
12 stars 13 forks source link

Adjust Markdent GitHub dialect parser to accept pandoc (v1.12, v1.13) ge... #4

Closed aspeer closed 9 years ago

aspeer commented 9 years ago

Hello Dave,

Thanks for the work on your Markdent module.

I have made a small adjustment to GitHub dialect markdown parser to accept markdown code generated by pandoc versions 1.12 and 1.13.

Pandoc v1.12 generates markdown code (single quotes used here to avoid github munging backticks)

''' {.lang}

Pandoc v1.13

''' lang (note space)

Neither of the above was recognised as code by Markdent - but is by the GitHub markdown processor. The regex has been adjusted to allow the above formats also.

Demo of pre and post patch output is available at:

[https://github.com/aspeer/markdown-pod-testing]

See the markdent_test files.

Thanks for your consideration .. Andrew

autarch commented 9 years ago

A test to go along with this would be greatly appreciated.

aspeer commented 9 years ago

Hello Dave, I have expanded the tests in t/markup/github/fenced-block.t to include the fenced block variations created by Pandoc .. Reds, Andrew

autarch commented 9 years ago

I merged this manually from the CLI. Thanks!