Markdown2

Latest version: v2.4.13

Safety actively analyzes 628903 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 7 of 10

1.3.0

Not secure
- Deprecate `code-color` extra. Use the `fenced-code-block` extra and
its cleaner mechanism for specifying the language, instead. This extra
will be removed in v2.0 or so.

- New `fenced-code-blocks` extra. It allows a code block to not have to be
indented by fencing it with '' on a line before and after. Based on
[GFM](<http://github.github.com/github-flavored-markdown/).

Some code:


print "hi"


It includes support for code syntax highlighting as per GFM. This requires
the `pygments` Python module to be on the pythonpath.

python
if True:
print "hi"

1.2.0

Not secure
- [issue 78, issue 77] Add "metadata" extra (github.com/slomo).

1.1.1

Not secure
- Drop "Makefile.py" (a `mk` thing) and simplify to "Makefile".

1.1.0

Not secure
- [issue 76] Ensure "smarty-pants" extra doesn't destroy image links
and links with title text.

- [issue 72] Support reading from stdin for command line tool like any
well-behaved unix tool, e.g.:

$ echo '*hi*' | markdown2
<p><em>hi</em></p>

Thanks Ryan!

- Drop this "1.0.1.*" version silliness. The idea *was* that the first three
numbers tracked the Markdown.pl on which markdown2.py was originally based.
I don't believe Markdown.pl really gets releases anymore tho, so pointless.

1.0.1.19

Not secure
- [Issue 66] Add "wiki-tables" extra for Google Code Wiki-style tables.
See <http://code.google.com/p/support/wiki/WikiSyntax#Tables>.

1.0.1.18

Not secure
- [Issue 57] Add html5 block tags (article, section, aside, et al; see
"_html5tags" variable) to Markdown literal HTML block tag handling. Thanks
Tim Gray!

- [Issue 56] Fix `setup.py install`.

- [Issue 54] Fix escaping of link title attributes. Thanks FND!

- Tweak list matching to NOT make a ul for something like this:

- - - - - hi there

Before this change this would be a silly 5-deep nested li. See
"not_quite_a_list" test case.

- [Issue 52] Fix potential pathologically slow matching for `<hr>` markdown
("slow_hr" test case).

- Add a `Markdown.postprocess(text) -> text` hook that is called near the end
of markdown conversion. By default this does no transformation. It is called
just before unescaping of special characters and unhashing of literal HTML
blocks.

- ["header-ids" and "toc" extras] Add "n" argument to
`Markdown.header_id_from_text` hook. This allows a subclass using this hook
to differentiate the header id based on the hN number (e.g. h1 diff that
h2). Also allow a `None` return value to not add an id to that header (and
exclude that header from the TOC).

Note: If you used this hook, this is an incompatible change to the call
signature.

- Add a "markdown-in-html" extra similar to (but limited)
<http://michelf.com/projects/php-markdown/extra/#markdown-attr>. I.e. this:

<div markdown="1">
Yo **yo**!
</div>

becomes:

<div>

Yo <strong>yo</strong>!

</div>

- [Issue 39] Test case fix for pygments 1.3.1 from thomas.moschny.

- [Issue 42] Add "smarty-pants" extra for transforming plain ASCII
punctuation characters into smart typographic punctuation HTML entities.
Inspiration: <http://daringfireball.net/projects/smartypants/>
Implementation by Nikhil Chelliah. Also add `\'` and `\"` escape sequences
for forcing dumb quotes when this extra is in use.

- Guard against using `True` instead of `None` as follows
`markdown(..., extras={'header-ids': True})`. `None` is wanted, but `True`
is commonly (at least I did it twice) used.

Page 7 of 10

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.