File: conf.py

package info (click to toggle)
intel-gpu-tools 2.2-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 63,368 kB
  • sloc: xml: 781,458; ansic: 360,567; python: 8,336; yacc: 2,781; perl: 1,196; sh: 1,177; lex: 487; asm: 227; lisp: 35; makefile: 30
file content (74 lines) | stat: -rw-r--r-- 1,562 bytes parent folder | download | duplicates (3)
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# -*- coding: utf-8 -*-
# SPDX-License-Identifier: (GPL-2.0 OR MIT)

import os
import sphinx
import sys

# Get Sphinx version
major, minor, patch = sphinx.version_info[:3]

sys.path.insert(0, os.path.abspath('sphinx'))

extensions = []

def which(program):
    import os
    def is_exe(fpath):
        return os.path.isfile(fpath) and os.access(fpath, os.X_OK)

    fpath, fname = os.path.split(program)
    if fpath:
        if is_exe(program):
            return program
    else:
        for path in os.environ["PATH"].split(os.pathsep):
            exe_file = os.path.join(path, program)
            if is_exe(exe_file):
                return exe_file

    return None

if which('rst2pdf'):
    extensions.append('rst2pdf.pdfbuilder')

source_suffix = '.rst'
master_doc = 'index'

project = 'IGT Test Tools'
copyright = 'Intel'
author = 'IGT developers'
language = 'en'

exclude_patterns = []
todo_include_todos = False

if major < 2 and minor < 6:
    html_use_smartypants = False
else:
    smartquotes = False

html_theme = "nature"

# body_max_width causes build error with nature theme on version < 1.7
if major < 2 and minor < 7:
    html_theme_options = {
        "sidebarwidth": "400px",
    }
else:
    html_theme_options = {
        "body_max_width": "1520px",
        "sidebarwidth": "400px",
    }

html_css_files = []
html_static_path = ['.']
html_copy_source = False

html_sidebars = { '**': ['searchbox.html', 'localtoc.html']}
htmlhelp_basename = 'IGT'

# rst2pdf
pdf_documents = [
    ('index', u'tests', u'IGT Xe Tests', u'IGT authors'),
]