properly configure theme, manual menu definition
This commit is contained in:
parent
4bd04c1386
commit
1558afdfea
9 changed files with 141 additions and 12 deletions
|
|
@ -1,15 +1,24 @@
|
|||
#!/usr/bin/env python
|
||||
#!/usr/bin/env python3
|
||||
# -*- coding: utf-8 -*- #
|
||||
|
||||
from datetime import datetime
|
||||
|
||||
AUTHOR = 'Trolli Schmittlauch'
|
||||
SITENAME = 'schmittlauch'
|
||||
SITENAME = 'Schmittlauchs Blog & Homepage'
|
||||
SITETITLE = 'schmittlauch'
|
||||
SITETITLE = 'Tech, Politik & Leben'
|
||||
SITEURL = ''
|
||||
SITELOGO = '/images/avatar.png'
|
||||
FAVICON = '/images/favicon.svg'
|
||||
|
||||
PATH = 'content'
|
||||
ARTICLE_PATHS = ['blog']
|
||||
INDEX_SAVE_AS = 'blog/index.html'
|
||||
|
||||
#CUSTOM_CSS = "static/custom.css"
|
||||
|
||||
TIMEZONE = 'Europe/Berlin'
|
||||
|
||||
DEFAULT_LANG = 'de'
|
||||
|
||||
# Feed generation is usually not desired when developing
|
||||
FEED_ALL_ATOM = None
|
||||
|
|
@ -18,15 +27,33 @@ TRANSLATION_FEED_ATOM = None
|
|||
AUTHOR_FEED_ATOM = None
|
||||
AUTHOR_FEED_RSS = None
|
||||
|
||||
# Blogroll
|
||||
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', '#'),)
|
||||
DISPLAY_PAGES_ON_MENU = False
|
||||
DISPLAY_CATEGORIES_ON_MENU = False
|
||||
MAIN_MENU = True
|
||||
MENUITEMS = (
|
||||
("Blog", SITEURL + "/blog/"),
|
||||
("Archives", "/archives.html"),
|
||||
("Categories", "/categories.html"),
|
||||
("Tags", "/tags.html"),
|
||||
("Impressum", "/pages/impressum.html"),
|
||||
)
|
||||
# lefthand menu
|
||||
LINKS = (('Blog', '/blog/'),
|
||||
('Über mich', '/pages/about.html'),
|
||||
('Berufliches & Lebenslauf', '/pages/professional.html'),
|
||||
('Kontakt', '/pages/contact.html'),
|
||||
#('', ''),
|
||||
)
|
||||
|
||||
# Social widget
|
||||
SOCIAL = (('You can add links in your config file', '#'),
|
||||
('Another social link', '#'),)
|
||||
SOCIAL = (
|
||||
("mastodon", "https://toot.matereal.eu/@schmittlauch"),
|
||||
("twitter", "https://twitter.com/schmittlauch"),
|
||||
#("matrixdotorg", ""),
|
||||
("envelope", "mailto:t.schmittlauch@orlives.de"),
|
||||
("git", "https://git.orlives.de/"),
|
||||
("github", "https://github.com/schmittlauch/"),
|
||||
)
|
||||
|
||||
DEFAULT_PAGINATION = 10
|
||||
|
||||
|
|
@ -34,14 +61,56 @@ DEFAULT_PAGINATION = 10
|
|||
#RELATIVE_URLS = True
|
||||
|
||||
# Multilang
|
||||
DEFAULT_LANG = 'de'
|
||||
OG_LOCALE = "de_DE"
|
||||
LOCALE = ("de_DE", "de_DE.utf8")
|
||||
|
||||
PLUGIN_PATHS = ['pelican-plugins']
|
||||
PLUGINS = ['i18n_subsites']
|
||||
# Enable Jinja2 i18n extension used to parse translations.
|
||||
JINJA_ENVIRONMENT = {'extensions': ['jinja2.ext.i18n']}
|
||||
# Default theme language.
|
||||
I18N_TEMPLATES_LANG = "en"
|
||||
|
||||
|
||||
I18N_SUBSITES = {
|
||||
'en': {
|
||||
(_LOC := 'en'): {
|
||||
'SITENAME': 'schmittlauch',
|
||||
'OG_LOCALE': "en",
|
||||
'LOCALE': ("en_GB", "en_GB.utf8"),
|
||||
|
||||
# translation of strings, menu, titles
|
||||
'SITETITLE': 'Tech, Politics & Life',
|
||||
'MENUITEMS': (
|
||||
("Blog", f"{_LOC}/blog/"),
|
||||
("Archives", f"{_LOC}/archives.html"),
|
||||
("Categories", f"{_LOC}/categories.html"),
|
||||
("Tags", f"{_LOC}/tags.html"),
|
||||
("Impressum", f"{_LOC}/pages/impressum.html"),
|
||||
),
|
||||
'LINKS': (
|
||||
('Blog', f'{_LOC}/blog/'),
|
||||
('About', f'{_LOC}/pages/about.html'),
|
||||
('Professional & CV', f'{_LOC}/pages/professional.html'),
|
||||
('Contact', f'{_LOC}/pages/contact.html'),
|
||||
#('', ''),
|
||||
),
|
||||
}
|
||||
}
|
||||
I18N_UNTRANSLATED_ARTICLES = 'keep'
|
||||
|
||||
# Theming and templates
|
||||
# Theming, templates, and specific configs
|
||||
THEME = './theme/Flex'
|
||||
|
||||
THEME_COLOR_AUTO_DETECT_BROWSER_PREFERENCE = True
|
||||
THEME_COLOR_ENABLE_USER_OVERRIDE = True
|
||||
|
||||
CC_LICENSE = {
|
||||
"name": "Creative Commons Attribution-ShareAlike",
|
||||
"version": "4.0",
|
||||
"slug": "by-sa",
|
||||
"icon": True,
|
||||
}
|
||||
COPYRIGHT_YEAR = datetime.now().year
|
||||
|
||||
USE_GOOGLE_FONTS = False
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue