Automatic links from code examples to reference documentation.
Project description
sphinx-codeautolink makes code examples clickable by inserting links from individual code elements to the corresponding reference documentation. We aim for a minimal setup assuming your examples are already valid Python.
For a live demo, see our online documentation on Read The Docs.
Installation
sphinx-codeautolink can be installed from the Package Index via pip.
$ pip install sphinx-codeautolink
Note that the library is in early development, so version pinning is advised. To enable sphinx-codeautolink, modify the extension list in conf.py. Note that the extension name uses an underscore rather than a hyphen.
extensions = [
...,
"sphinx_codeautolink",
]
That’s it! Now your code examples are linked. For ways of concatenating multiple examples and setting default import statements among other things, have a look at the online documentation.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for sphinx-codeautolink-0.10.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 68a75f9955b2fac0f5fc0c7ff1d3058df074edd8061b857958223be425b01183 |
|
MD5 | 4d876a4c08234fce61362a7258e0451d |
|
BLAKE2b-256 | 0e6cd97adb0b820b94e3d8883a85f8f324e2134d020c1ce10bbdebf9817ddc3f |
Hashes for sphinx_codeautolink-0.10.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c8c9e95cb83c7d6547d904db4432f2fac88e6c68421c0cf97c84cccdbe57dcdd |
|
MD5 | 26e404c943777634b32c3165570c7aeb |
|
BLAKE2b-256 | b943c545dc3ae6701bce57c1de2c1bd669c24ceec54edba3e0dab2e93b970b4d |