blob: 9eb9afe1e7a1f91ced85e757ffd2d4c03aa198cb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
smartypants
===========
smartypants_ is a Python fork of SmartyPants__.
.. _smartypants: https://bitbucket.org/livibetter/smartypants.py
__ SmartyPantsPerl_
.. _SmartyPantsPerl: http://daringfireball.net/projects/smartypants/
Installation
------------
To install it:
.. code:: sh
pip install smartypants
Quick usage
-----------
To use it as a module:
.. code:: python
import smartypants
text = '"SmartyPants" is smart, so is <code>smartypants</code> -- a Python port'
print(smartypants.smartypants(text))
To use the command-line script ``smartypants``:
.. code:: sh
echo '"SmartyPants" is smart, so is <code>smartypants</code> -- a Python port' | smartypants
Both produce::
“SmartyPants” is smart, so is <code>smartypants</code> — a Python port
More information
----------------
* Documentation_
* `Source code`_
* PyPI_
.. _documentation: http://pythonhosted.org/smartypants/
.. _Source code: smartypants_
.. _PyPI: https://pypi.python.org/pypi/smartypants/
|