Created
June 1, 2016 13:07
-
-
Save kezabelle/e947bfa0511f311ecd70661fdc273f8a to your computer and use it in GitHub Desktop.
gimme
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
import markdown2 | |
z = re.compile('\<(?P<lol>h[1-6])\>(.+?)\<\/(?P=lol)\>') | |
x = """ | |
#### lol | |
## lol | |
<h1>lol</h1> | |
\n``` | |
<h2>heh</h2> | |
``` | |
""" | |
y = markdown2.markdown(x, extras=['fenced-code-blocks', 'metadata', 'footnotes']) | |
z.findall(y) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment