Tell appart Markdown and reStructuredText.
The package exposes a single function, sniff(content)
, trying to
deduce the format used, returning it as a string: md
, rst
or
txt
:
>>> import mdorrst
>>> mdorrst.sniff("[hey](http://example.com)")
'md'
>>> mdorrst.sniff("`hey <http://example.com>`__")
'rst'