A flake8 plugin which checks docstrings for double backticked strings that should be links to the Python documentation.
Project description
A flake8 plugin which checks docstrings for double backticked strings that should be links to the Python documentation.
Docs |
|
---|---|
Tests |
|
PyPI |
|
Anaconda |
|
Activity |
|
Other |
For example, ``True`` should be py:obj:`True`, which Sphinx will render as a link to the Python documentation.
reStructuredText .rst files are not currently checked.
Installation
flake8_sphinx_links can be installed from PyPI or Anaconda.
To install with pip:
$ python -m pip install flake8_sphinx_links
To install with conda:
First add the required channels
$ conda config --add channels http://conda.anaconda.org/domdfcoding $ conda config --add channels http://conda.anaconda.org/conda-forge
Then install
$ conda install flake8_sphinx_links
flake8 codes
Code |
Description |
---|---|
SXL001 |
Double backticked variable should be a link to Python documentation. |
Use as a pre-commit hook
See pre-commit for instructions
Sample .pre-commit-config.yaml:
- repo: https://gitlab.com/pycqa/flake8
rev: 3.8.1
hooks:
- id: flake8
additional_dependencies: [flake8-sphinx-links==0.1.0]
Project details
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 flake8_sphinx_links-0.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2af1ef60f0af38421ff9459784e5816dc4d83c4911ec4e8854a9105340b74d58 |
|
MD5 | efd1f5bc1fe91cc898a53825f830ffcb |
|
BLAKE2b-256 | 73049f55c65278370fa2bb8413df9cb7fba9be366d82dbd96c90a62c78503dab |
Hashes for flake8_sphinx_links-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 68fffba685b24fd7f695d254b838a4157c12c11f7475b7d48f742475cdbd41bb |
|
MD5 | 7c7243bd379c2ddf20f735ef17db19be |
|
BLAKE2b-256 | 64e0722a9b0a076adcbcfd6933b57696f9edc10b07bd77f1d802877caf0007ed |