2023-02-20 15:01:31 +00:00
|
|
|
#
|
|
|
|
import os
|
|
|
|
|
2023-02-20 11:34:00 +00:00
|
|
|
AUTHOR = 'Андрей Астафьев'
|
|
|
|
SITENAME = 'ДСП'
|
|
|
|
SITEURL = 'https://dsp.246060.ru'
|
|
|
|
|
|
|
|
PATH = 'docs'
|
|
|
|
CACHE_PATH = 'cache'
|
|
|
|
|
|
|
|
TIMEZONE = 'Europe/Moscow'
|
|
|
|
|
|
|
|
DEFAULT_LANG = 'ru'
|
|
|
|
|
|
|
|
# Generation time
|
|
|
|
CACHE_CONTENT = True
|
|
|
|
LOAD_CONTENT_CACHE = True
|
|
|
|
|
|
|
|
# Feed generation is usually not desired when developing
|
|
|
|
FEED_ALL_ATOM = None
|
|
|
|
CATEGORY_FEED_ATOM = None
|
|
|
|
TRANSLATION_FEED_ATOM = None
|
|
|
|
AUTHOR_FEED_ATOM = None
|
|
|
|
AUTHOR_FEED_RSS = None
|
|
|
|
|
2023-02-20 15:01:31 +00:00
|
|
|
USE_FOLDER_AS_CATEGORY = True
|
2023-02-20 11:34:00 +00:00
|
|
|
DEFAULT_DATE = 'fs'
|
|
|
|
STATIC_PATHS = ['images', 'files', 'extras']
|
2023-02-20 15:01:31 +00:00
|
|
|
DIRECT_TEMPLATES = ('index', 'categories', 'authors', 'archives')
|
2023-02-20 11:34:00 +00:00
|
|
|
|
|
|
|
EXTRA_PATH_METADATA = {
|
|
|
|
'extras/favicon.ico': {'path': 'favicon.ico'},
|
|
|
|
}
|
|
|
|
|
2023-02-20 15:01:31 +00:00
|
|
|
DISPLAY_CATEGORIES_ON_MENU = False
|
|
|
|
DISPLAY_CATEGORIES_ON_SIDEBAR = True
|
|
|
|
DISPLAY_TAGS_ON_SIDEBAR = True
|
|
|
|
|
|
|
|
THEME = 'themes/bootstrap4'
|
|
|
|
BOOTSTRAP_THEME = 'litera'
|
|
|
|
|
|
|
|
# I18N_GETTEXT_LOCALEDIR = 'translations'
|
|
|
|
# I18N_GETTEXT_DOMAIN = 'messages'
|
|
|
|
|
|
|
|
# Обязательно в виде массива
|
|
|
|
I18N_TEMPLATES_LANG = ['ru']
|
|
|
|
I18N_GETTEXT_NEWSTYLE = True
|
|
|
|
JINJA_ENVIRONMENT = {'extensions': ['jinja2.ext.i18n']}
|
|
|
|
|
|
|
|
PLUGIN_PATHS = ["plugins/official", "plugins/thirdparty"]
|
|
|
|
PLUGINS = ["css", "i18n_subsites", "pandoc-reader", "pelidoc", "replacer",
|
|
|
|
"search", "series", "subcategory", "tag_cloud"]
|
|
|
|
# PLUGINS = ["better_tables", "just_table"]
|
|
|
|
|
|
|
|
TEMPLATES_PATH = "templates"
|
|
|
|
|
|
|
|
PANDOC_READER_HTML_TEMPLATE = "wiki"
|
|
|
|
|
|
|
|
PANDOC_OUTPUTS = {
|
|
|
|
'pdf': 'pdf',
|
|
|
|
}
|
|
|
|
|
|
|
|
PANDOC_ARGS = [
|
|
|
|
"--variable=documentclass:extarticle",
|
|
|
|
"--variable=toc-title:Содержание",
|
|
|
|
"--highlight-style=tango",
|
|
|
|
"--filter=skip-toc-tag",
|
|
|
|
"--filter=pandoc_plantuml_filter.py",
|
|
|
|
"--template=wiki",
|
|
|
|
"--resource-path=wiki:."
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
|
|
PANDOC_EXTRA_OPTIONS = PANDOC_ARGS + ["--pdf-engine=xelatex"]
|
|
|
|
|
|
|
|
PANDOC_MARKDOWN_EXTENSIONS = [
|
|
|
|
"+smart",
|
|
|
|
"+backtick_code_blocks",
|
|
|
|
"+fenced_code_blocks",
|
|
|
|
"+fenced_code_attributes",
|
|
|
|
"+fenced_divs",
|
|
|
|
"+native_divs",
|
|
|
|
"+bracketed_spans",
|
|
|
|
"+native_spans"
|
|
|
|
]
|
|
|
|
|
|
|
|
PANDOC_EXTENSIONS = PANDOC_MARKDOWN_EXTENSIONS
|
|
|
|
|
|
|
|
REPLACES = (
|
|
|
|
('{}/docs/'.format(os.getcwd()), u''),
|
|
|
|
)
|
|
|
|
|
|
|
|
YUICOMPRESSOR_EXECUTABLE = "yui-compressor"
|
|
|
|
YUICOMPRESSOR_EXTRA_OPTIONS = ["--nomunge"]
|
|
|
|
|
|
|
|
if 'COMPRESS' in os.environ:
|
|
|
|
PLUGINS += ["yuicompressor-opt"]
|
|
|
|
|
|
|
|
|
|
|
|
PDF_PROCESSOR = True
|
|
|
|
|
2023-02-20 11:34:00 +00:00
|
|
|
# Blogroll
|
|
|
|
LINKS = ()
|
|
|
|
# LINKS = (('Pelican', 'https://getpelican.com/'),
|
|
|
|
# ('Python.org', 'https://www.python.org/'),
|
|
|
|
# ('Jinja2', 'https://palletsprojects.com/p/jinja/'),
|
|
|
|
# ('You can modify those links in your config file', '#'),)
|
|
|
|
|
|
|
|
# Social widget
|
|
|
|
SOCIAL = ()
|
|
|
|
# SOCIAL = (('You can add links in your config file', '#'),
|
|
|
|
# ('Another social link', '#'),)
|
|
|
|
|
2023-02-20 15:01:31 +00:00
|
|
|
PYGMENTS_STYLE='pastie'
|
|
|
|
|
2023-02-20 11:34:00 +00:00
|
|
|
DEFAULT_PAGINATION = 20
|
|
|
|
|
|
|
|
# Uncomment following line if you want document-relative URLs when developing
|
|
|
|
RELATIVE_URLS = True
|