Skip to main content

Alternative method for documenting enums with Sphinx.

Project description

Alternative method for documenting enums with Sphinx.

Docs

Documentation Build Status Docs Check Status

Tests

Travis Build Status Windows Tests Status macOS Tests Status Coverage CodeFactor Grade

PyPI

PyPI - Package Version PyPI - Supported Python Versions PyPI - Supported Implementations PyPI - Wheel

Anaconda

Conda - Package Version Conda - Platform

Activity

GitHub last commit GitHub commits since tagged version Maintenance

Other

License GitHub top language Requirements Status pre-commit


This package has two features:

  1. A decorator to add docstrings to Enum members from a comment at the end of the line.

  2. A Sphinx extension to document Enums better than autoclass can currently.

Installation

enum_tools can be installed from PyPI or Anaconda.

To install with pip:

$ python -m pip install enum_tools

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 enum_tools

Further Reading

  1. https://docs.python.org/3/library/enum.html

  2. Is it possible to define a class constant inside an Enum?

  3. Enums with Attributes

  4. When should I subclass EnumMeta instead of Enum?

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

enum_tools-0.2.0.tar.gz (17.7 kB view hashes)

Uploaded Source

Built Distribution

enum_tools-0.2.0-py3-none-any.whl (19.2 kB view hashes)

Uploaded Python 3

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