constants¶
This module contains constants used throughout the chango package.
- class chango.constants.MarkupLanguage(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)¶
Commonly known markup languages
- HTML = 'html'¶
- POD = 'pod'¶
The Plain Old Documentation markup language
- RESTRUCTUREDTEXT = 'rst'¶
The reStructuredText markup language
- TEXT = 'txt'¶
Plain text
- classmethod from_string(string, mapping=None)¶
Get the markup language enum member from a string by comparing against the members of this enum as well as commonly used file extensions. Case-insensitive. Leading dots are ignored.
- Parameters:
- Returns:
The markup language enum member.
- Return type:
- Raises:
ValueError – If the file extension can not be resolved to a markup language.