blob: c20ed3d7e43065205d08daa393ffe1958dd8a50b [file] [log] [blame]
Luigi Santivettif72f6572020-02-17 23:11:56 +00001#!/usr/bin/env python
2# -*- coding: utf-8 -*- #
3from __future__ import unicode_literals
luigi14ab4f82020-04-04 22:06:26 +01004import os
Luigi Santivettif72f6572020-02-17 23:11:56 +00005
6# For an exhaustive list of available variables and how to use them refer to
7# http://docs.getpelican.com/en/stable/settings.html
8
9# Reference for signing off posts
10AUTHOR = 'Luigi'
11
12# Reference to the site name
13SITENAME = 'Giggi.me'
14
15# Custom variable, introduced for keeping requests cosistent
16INDEX_LINK_AS = 'blog.html'
17
18# If set, stop treating index.html as default posts binder
19INDEX_SAVE_AS = INDEX_LINK_AS
20
21# URL path to the root
22SITEURL = 'https://www.giggi.me'
23
24# URL path to the theme folder
25THEMEURL = SITEURL
26
27# Local path to the markdown source folder
28PATH = 'content'
29
30# Local path to the current theme folder
31THEME = 'theme'
32
33# Default time zone
34TIMEZONE = 'Europe/London'
35
36# The default date format you want to use.
37DEFAULT_DATE_FORMAT = '%a %B %d %Y'
38
39# The extensions to use when looking up template files from template names.
40TEMPLATE_EXTENSION = [ '.html' ]
41
42# Default language
43DEFAULT_LANG = 'en'
44
45# Feed generation is usually not desired when developing
46FEED_ALL_ATOM = None
47
48#
49CATEGORY_FEED_ATOM = None
50
51#
52TRANSLATION_FEED_ATOM = None
53
54#
55AUTHOR_FEED_ATOM = None
56
57#
58AUTHOR_FEED_RSS = None
59
60# Social widget
61SOCIAL = (
62 ('Linux', 'https://www.debian.org'),
63 ('Mail', 'mailto:luigi.santivetti@gmail.com'),
64)
65
66#
67DEFAULT_PAGINATION = False
68
69# List of plugins paths utilised by this site
70PLUGIN_PATHS = [
71 'theme/plugins',
72]
73
74# List of plugins names
75PLUGINS = [
76 'assets',
77 'photos',
78]
79
80# Derive categories from the folder name
81USE_FOLDER_AS_CATEGORY = False
82
83# Show shortcuts to categories
84DISPLAY_CATEGORIES_ON_MENU = True
85
86# Show shortcuts to static pages (i.e. non articles)
87DISPLAY_PAGES_ON_MENU = False
88
89# Use cached html
90LOAD_CONTENT_CACHE = False
91
92# List of menu items
93MENUITEMS = [
94 ('Git', 'page/git.html'),
95 ('Mail', 'page/mail.html'),
96 ('Ftp', 'page/ftp.html'),
97 ('About', 'page/about.html'),
98 ('Invite', 'page/invite.html'),
99 ('Login', 'page/login.html'),
100]
101
102# Enable line numbers
103# https://python-markdown.github.io/reference/#markdown
104MARKDOWN = {
105 'extension_configs': {
106 'markdown.extensions.codehilite': {'css_class': 'highlight', 'linenums' : True},
107 'markdown.extensions.extra': {},
108 'markdown.extensions.meta': {},
109 },
110 'output_format': 'html5',
111}
112
113#
114# Defines whether Pelican should use document-relative URLs or not. Only set
115# this to True when developing/testing# and only if you fully understand the
116# effect it can have on links/feeds.
117#RELATIVE_URLS = True
118
119# The URL to refer to an article.
120ARTICLE_URL = 'blog/{slug}.html'
121
122# The place where we will save an article.
123ARTICLE_SAVE_AS = 'blog/{slug}.html'
124
125# The URL to refer to an article which doesn’t use the default language.
126ARTICLE_LANG_URL = 'blog/{slug}-{lang}.html'
127
128# The place where we will save an article which doesn’t use the default
129# language.
130ARTICLE_LANG_SAVE_AS = 'blog/{slug}-{lang}.html'
131
132# The URL to refer to an article draft.
133DRAFT_URL = 'draft/blog/{slug}.html'
134
135# The place where we will save an article draft.
136DRAFT_SAVE_AS = 'draft/blog/{slug}.html'
137
138# The URL to refer to an article draft which doesn’t use the default language.
139DRAFT_LANG_URL = 'draft/blog/{slug}-{lang}.html'
140
141# The place where we will save an article draft which doesn’t use the default
142# language.
143DRAFT_LANG_SAVE_AS = 'draft/blog/{slug}-{lang}.html'
144
145# The URL we will use to link to a page.
146PAGE_URL = 'page/{slug}.html'
147
148# The location we will save the page. This value has to be the same as PAGE_URL
149# or you need to use a rewrite in your server config.
150PAGE_SAVE_AS = 'page/{slug}.html'
151
152# The URL we will use to link to a page which doesn’t use the default language.
153PAGE_LANG_URL = 'page/{slug}-{lang}.html'
154
155#The location we will save the page which doesn’t use the default language.
156PAGE_LANG_SAVE_AS = 'page/{slug}-{lang}.html'
157
158# The URL used to link to a page draft.
159DRAFT_PAGE_URL = 'draft/page/{slug}.html'
160
161# The actual location a page draft is saved at.
162DRAFT_PAGE_SAVE_AS = 'draft/page/{slug}.html'
163
164# The URL used to link to a page draft which doesn’t use the default language.
165DRAFT_PAGE_LANG_URL = 'draft/page/{slug}-{lang}.html'
166
167# The actual location a page draft which doesn’t use the default language is
168# saved at.
169DRAFT_PAGE_LANG_SAVE_AS = 'draft/page/{slug}-{lang}.html'
170
171# The URL to use for a category.
172CATEGORY_URL = 'category/{slug}.html'
173
174# The location to save a category.
175CATEGORY_SAVE_AS = 'category/{slug}.html'
176
177# The URL to use for a tag.
178TAG_URL = 'tag/{slug}.html'
179
180# The location to save the tag page.
181TAG_SAVE_AS = 'tag/{slug}.html'
182
183# The URL to use for an author.
184AUTHOR_URL = 'author/{slug}.html'
185
186# The location to save an author.
187AUTHOR_SAVE_AS = 'author/{slug}.html'
188
189# The location to save per-year archives of your posts.
190YEAR_ARCHIVE_SAVE_AS = 'blog/{date:%Y}/index.html'
191
192# The URL to use for per-year archives of your posts. Used only if you have the
193# {url} placeholder in PAGINATION_PATTERNS.
194YEAR_ARCHIVE_URL = ''
195
196# The location to save per-month archives of your posts.
197MONTH_ARCHIVE_SAVE_AS = 'blog/{date:%Y}/{date:%b}/index.html'
198
199# The URL to use for per-month archives of your posts. Used only if you have the
200# {url} placeholder in PAGINATION_PATTERNS.
201MONTH_ARCHIVE_URL = ''
202
203# The location to save per-day archives of your posts.
204DAY_ARCHIVE_SAVE_AS = 'blog/{date:%Y}/{date:%b}/{date:%d}/index.html'
205
206# The URL to use for per-day archives of your posts. Used only if you have the
207# {url} placeholder in PAGINATION_PATTERNS.
208DAY_ARCHIVE_URL = ''
209
210# Gallery plugin
luigi14ab4f82020-04-04 22:06:26 +0100211PHOTO_LIBRARY = os.getenv('PELICAN_PHOTO_LIBRARY')
212PHOTO_EXCLUDE = os.getenv('PELICAN_PHOTO_EXCLUDE')
213PHOTO_EXCLUDEALL = os.getenv('PELICAN_PHOTO_EXCLUDEALL')
Luigi Santivettif72f6572020-02-17 23:11:56 +0000214PHOTO_GALLERY = (2000, 1333, 100)
215PHOTO_ARTICLE = (2000, 1333, 100)
216PHOTO_THUMB = (300, 200, 100)
217PHOTO_SQUARE_THUMB = False