123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379 |
- from __future__ import unicode_literals
- import sys
- from os.path import abspath, dirname, join
- sys.setrecursionlimit(2000)
- sys.path.insert(1, dirname(dirname(abspath(__file__))))
- sys.path.append(abspath(join(dirname(__file__), "_ext")))
- needs_sphinx = '1.3'
- extensions = [
- "djangodocs",
- "sphinx.ext.intersphinx",
- "sphinx.ext.viewcode",
- "ticket_role",
- "cve_role",
- ]
- if 'spelling' in sys.argv:
- extensions.append("sphinxcontrib.spelling")
- spelling_lang = 'en_US'
- spelling_word_list_filename = 'spelling_wordlist'
- source_suffix = '.txt'
- master_doc = 'contents'
- project = 'Django'
- copyright = 'Django Software Foundation and contributors'
- version = '1.11'
- try:
- from django import VERSION, get_version
- except ImportError:
- release = version
- else:
- def django_release():
- pep440ver = get_version()
- if VERSION[3:5] == ('alpha', 0) and 'dev' not in pep440ver:
- return pep440ver + '.dev'
- return pep440ver
- release = django_release()
- django_next_version = '1.11'
- locale_dirs = ['locale/']
- today_fmt = '%B %d, %Y'
- exclude_patterns = ['_build']
- add_function_parentheses = True
- add_module_names = False
- show_authors = False
- pygments_style = 'trac'
- intersphinx_mapping = {
- 'python': ('https://docs.python.org/3/', None),
- 'sphinx': ('http://sphinx-doc.org/', None),
- 'six': ('https://pythonhosted.org/six/', None),
- 'formtools': ('https://django-formtools.readthedocs.io/en/latest/', None),
- 'psycopg2': ('http://initd.org/psycopg/docs/', None),
- }
- intersphinx_cache_limit = 90
- suppress_warnings = ['app.add_directive']
- html_theme = "djangodocs"
- html_theme_path = ["_theme"]
- html_last_updated_fmt = '%b %d, %Y'
- html_use_smartypants = True
- html_additional_pages = {}
- htmlhelp_basename = 'Djangodoc'
- modindex_common_prefix = ["django."]
- rst_epilog = """
- .. |django-users| replace:: :ref:`django-users <django-users-mailing-list>`
- .. |django-core-mentorship| replace:: :ref:`django-core-mentorship <django-core-mentorship-mailing-list>`
- .. |django-developers| replace:: :ref:`django-developers <django-developers-mailing-list>`
- .. |django-announce| replace:: :ref:`django-announce <django-announce-mailing-list>`
- .. |django-updates| replace:: :ref:`django-updates <django-updates-mailing-list>`
- """
- latex_elements = {
- 'preamble': (
- '\\DeclareUnicodeCharacter{2264}{\\ensuremath{\\le}}'
- '\\DeclareUnicodeCharacter{2265}{\\ensuremath{\\ge}}'
- '\\DeclareUnicodeCharacter{2665}{[unicode-heart]}'
- '\\DeclareUnicodeCharacter{2713}{[unicode-checkmark]}'
- ),
- }
- latex_documents = [
- ('contents', 'django.tex', 'Django Documentation',
- 'Django Software Foundation', 'manual'),
- ]
- man_pages = [(
- 'ref/django-admin',
- 'django-admin',
- 'Utility script for the Django Web framework',
- ['Django Software Foundation'],
- 1
- ), ]
- texinfo_documents = [(
- master_doc, "django", "", "", "Django",
- "Documentation of the Django framework", "Web development", False
- )]
- epub_title = project
- epub_author = 'Django Software Foundation'
- epub_publisher = 'Django Software Foundation'
- epub_copyright = copyright
- epub_theme = 'djangodocs-epub'
- epub_cover = ('', 'epub-cover.html')
- cve_url = 'https://web.nvd.nist.gov/view/vuln/detail?vulnId=%s'
- ticket_url = 'https://code.djangoproject.com/ticket/%s'
|