File: conf.py

package info (click to toggle)
python-sybil 9.2.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,148 kB
  • sloc: python: 4,510; makefile: 90
file content (59 lines) | stat: -rw-r--r-- 1,793 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# -*- coding: utf-8 -*-
import os, pkg_resources, datetime, time, sys

def check_object_path(key, url, path):
    if path and os.path.isfile(path):
        return {key: (url, path)}
    return {}

intersphinx_mapping = {}
intersphinx_mapping.update(
    check_object_path('python',
                      'https://docs.python.org/3/',
                      '/usr/share/doc/python%d.%d/html/objects.inv' % \
                       sys.version_info[:2]))
intersphinx_mapping.update(
    check_object_path('sphinx',
                      'http://www.sphinx-doc.org/en/master/',
                      '/usr/share/doc/sphinx-doc/html/objects.inv'))
intersphinx_mapping.update(
    check_object_path('myst',
                      'https://myst-parser.readthedocs.io/en/latest',
                      None))  # the docs are not packaged

extensions = [
    'sphinx.ext.autodoc',
    'sphinx.ext.intersphinx'
    ]

# General
source_suffix = '.rst'
master_doc = 'index'
project = 'sybil'
build_date = datetime.datetime.utcfromtimestamp(int(os.environ.get('SOURCE_DATE_EPOCH', time.time())))
copyright = '2017 - %s Chris Withers' % build_date.year
version = release = pkg_resources.get_distribution(project).version
exclude_patterns = [
    '_build',
    'example*',
]
pygments_style = 'sphinx'

# Options for HTML output
html_theme = 'furo'
html_title = 'Sybil'
htmlhelp_basename = project+'doc'

# Options for LaTeX output
latex_documents = [
  ('index',project+'.tex', project+u' Documentation',
   'Chris Withers', 'manual'),
]

autodoc_member_order = 'bysource'
nitpicky = True
nitpick_ignore = [
    ('py:class', 'Evaluator'),  # https://github.com/sphinx-doc/sphinx/issues/10785
    ('py:class', 'LexemeMapping'),  # https://github.com/sphinx-doc/sphinx/issues/10785
]
toc_object_entries = False