Skip to main content

Checks syntax of reStructuredText and code blocks nested within it

Project description

General

Maintenance - intended License Semantic Versioning - 2.0.0

Read the Docs - Build Status (latest)

CI

Test status Documentation status QA status pre-commit status

PyPI

PyPI - Package latest release PyPI - Supported Python Versions PyPI - Supported Implementations

PyPI - Format PyPI - Monthly downloads

Github

Github - Latest Release GitHub - Last Commit

Github - Stars Github - Forks Github - Contributors Github - Watchers

Checks syntax of reStructuredText and code blocks nested within it.

See the full documentation at read-the-docs

Installation

From pip

$ pip install rstcheck

To use pyproject.toml for configuration:

$ pip install rstcheck[toml]

To add sphinx support:

$ pip install rstcheck[sphinx]

Supported languages in code blocks

  • Bash

  • Doctest

  • C (C99)

  • C++ (C++11)

  • JSON

  • XML

  • Python

  • reStructuredText

Examples

With bad Python syntax:

====
Test
====

.. code:: python

    print(
$ rstcheck bad_python.rst
bad_python.rst:7: (ERROR/3) (python) unexpected EOF while parsing

With bad C++ syntax:

====
Test
====

.. code:: cpp

    int main()
    {
        return x;
    }
$ rstcheck bad_cpp.rst
bad_cpp.rst:9: (ERROR/3) (cpp) error: 'x' was not declared in this scope

With bad syntax in the reStructuredText document itself:

====
Test
===
$ rstcheck bad_rst.rst
bad_rst.rst:1: (SEVERE/4) Title overline & underline mismatch.

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

rstcheck-6.1.2.tar.gz (16.6 kB view details)

Uploaded Source

Built Distribution

rstcheck-6.1.2-py3-none-any.whl (6.9 kB view details)

Uploaded Python 3

File details

Details for the file rstcheck-6.1.2.tar.gz.

File metadata

  • Download URL: rstcheck-6.1.2.tar.gz
  • Upload date:
  • Size: 16.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.0 CPython/3.8.10 Linux/5.4.0-137-generic

File hashes

Hashes for rstcheck-6.1.2.tar.gz
Algorithm Hash digest
SHA256 f9cb07a72ef9a81d1e32187eae29b00a89421ccba1bde0b1652a08ed0923f61b
MD5 7c8848bcf8132f8dd61a247a28774155
BLAKE2b-256 4b0a1092b3000e15d257e15b481b49e5b257cc522ab05ff06010a4adb5fc4622

See more details on using hashes here.

File details

Details for the file rstcheck-6.1.2-py3-none-any.whl.

File metadata

  • Download URL: rstcheck-6.1.2-py3-none-any.whl
  • Upload date:
  • Size: 6.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.4.0 CPython/3.8.10 Linux/5.4.0-137-generic

File hashes

Hashes for rstcheck-6.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4aaa46e0debc179f849807c453fa384fd2b75167faf5b1274115730805fab529
MD5 f3685279caf5bb3b75ea77de6805aac4
BLAKE2b-256 f5690db8d50cc3b0cc4f7887d15b3e72fcaa8517b56bba6e4d8677174271148d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page