Luigi Santivetti | f72f657 | 2020-02-17 23:11:56 +0000 | [diff] [blame] | 1 | #!/usr/bin/env python |
| 2 | # -*- coding: utf-8 -*- # |
| 3 | from __future__ import unicode_literals |
luigi | 14ab4f8 | 2020-04-04 22:06:26 +0100 | [diff] [blame] | 4 | import os |
Luigi Santivetti | f72f657 | 2020-02-17 23:11:56 +0000 | [diff] [blame] | 5 | |
| 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 |
| 10 | AUTHOR = 'Luigi' |
| 11 | |
| 12 | # Reference to the site name |
| 13 | SITENAME = 'Giggi.me' |
| 14 | |
| 15 | # Custom variable, introduced for keeping requests cosistent |
| 16 | INDEX_LINK_AS = 'blog.html' |
| 17 | |
| 18 | # If set, stop treating index.html as default posts binder |
| 19 | INDEX_SAVE_AS = INDEX_LINK_AS |
| 20 | |
| 21 | # URL path to the root |
| 22 | SITEURL = 'https://www.giggi.me' |
| 23 | |
| 24 | # URL path to the theme folder |
| 25 | THEMEURL = SITEURL |
| 26 | |
| 27 | # Local path to the markdown source folder |
| 28 | PATH = 'content' |
| 29 | |
| 30 | # Local path to the current theme folder |
| 31 | THEME = 'theme' |
| 32 | |
| 33 | # Default time zone |
| 34 | TIMEZONE = 'Europe/London' |
| 35 | |
| 36 | # The default date format you want to use. |
| 37 | DEFAULT_DATE_FORMAT = '%a %B %d %Y' |
| 38 | |
| 39 | # The extensions to use when looking up template files from template names. |
| 40 | TEMPLATE_EXTENSION = [ '.html' ] |
| 41 | |
| 42 | # Default language |
| 43 | DEFAULT_LANG = 'en' |
| 44 | |
| 45 | # Feed generation is usually not desired when developing |
| 46 | FEED_ALL_ATOM = None |
| 47 | |
| 48 | # |
| 49 | CATEGORY_FEED_ATOM = None |
| 50 | |
| 51 | # |
| 52 | TRANSLATION_FEED_ATOM = None |
| 53 | |
| 54 | # |
| 55 | AUTHOR_FEED_ATOM = None |
| 56 | |
| 57 | # |
| 58 | AUTHOR_FEED_RSS = None |
| 59 | |
| 60 | # Social widget |
| 61 | SOCIAL = ( |
| 62 | ('Linux', 'https://www.debian.org'), |
| 63 | ('Mail', 'mailto:luigi.santivetti@gmail.com'), |
| 64 | ) |
| 65 | |
| 66 | # |
| 67 | DEFAULT_PAGINATION = False |
| 68 | |
| 69 | # List of plugins paths utilised by this site |
| 70 | PLUGIN_PATHS = [ |
luigi | de8ceeb | 2020-04-07 11:11:18 +0100 | [diff] [blame^] | 71 | 'plugins', |
Luigi Santivetti | f72f657 | 2020-02-17 23:11:56 +0000 | [diff] [blame] | 72 | ] |
| 73 | |
| 74 | # List of plugins names |
| 75 | PLUGINS = [ |
| 76 | 'assets', |
| 77 | 'photos', |
| 78 | ] |
| 79 | |
| 80 | # Derive categories from the folder name |
| 81 | USE_FOLDER_AS_CATEGORY = False |
| 82 | |
| 83 | # Show shortcuts to categories |
| 84 | DISPLAY_CATEGORIES_ON_MENU = True |
| 85 | |
| 86 | # Show shortcuts to static pages (i.e. non articles) |
| 87 | DISPLAY_PAGES_ON_MENU = False |
| 88 | |
| 89 | # Use cached html |
| 90 | LOAD_CONTENT_CACHE = False |
| 91 | |
| 92 | # List of menu items |
| 93 | MENUITEMS = [ |
| 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 |
| 104 | MARKDOWN = { |
| 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. |
| 120 | ARTICLE_URL = 'blog/{slug}.html' |
| 121 | |
| 122 | # The place where we will save an article. |
| 123 | ARTICLE_SAVE_AS = 'blog/{slug}.html' |
| 124 | |
| 125 | # The URL to refer to an article which doesn’t use the default language. |
| 126 | ARTICLE_LANG_URL = 'blog/{slug}-{lang}.html' |
| 127 | |
| 128 | # The place where we will save an article which doesn’t use the default |
| 129 | # language. |
| 130 | ARTICLE_LANG_SAVE_AS = 'blog/{slug}-{lang}.html' |
| 131 | |
| 132 | # The URL to refer to an article draft. |
| 133 | DRAFT_URL = 'draft/blog/{slug}.html' |
| 134 | |
| 135 | # The place where we will save an article draft. |
| 136 | DRAFT_SAVE_AS = 'draft/blog/{slug}.html' |
| 137 | |
| 138 | # The URL to refer to an article draft which doesn’t use the default language. |
| 139 | DRAFT_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. |
| 143 | DRAFT_LANG_SAVE_AS = 'draft/blog/{slug}-{lang}.html' |
| 144 | |
| 145 | # The URL we will use to link to a page. |
| 146 | PAGE_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. |
| 150 | PAGE_SAVE_AS = 'page/{slug}.html' |
| 151 | |
| 152 | # The URL we will use to link to a page which doesn’t use the default language. |
| 153 | PAGE_LANG_URL = 'page/{slug}-{lang}.html' |
| 154 | |
| 155 | #The location we will save the page which doesn’t use the default language. |
| 156 | PAGE_LANG_SAVE_AS = 'page/{slug}-{lang}.html' |
| 157 | |
| 158 | # The URL used to link to a page draft. |
| 159 | DRAFT_PAGE_URL = 'draft/page/{slug}.html' |
| 160 | |
| 161 | # The actual location a page draft is saved at. |
| 162 | DRAFT_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. |
| 165 | DRAFT_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. |
| 169 | DRAFT_PAGE_LANG_SAVE_AS = 'draft/page/{slug}-{lang}.html' |
| 170 | |
| 171 | # The URL to use for a category. |
| 172 | CATEGORY_URL = 'category/{slug}.html' |
| 173 | |
| 174 | # The location to save a category. |
| 175 | CATEGORY_SAVE_AS = 'category/{slug}.html' |
| 176 | |
| 177 | # The URL to use for a tag. |
| 178 | TAG_URL = 'tag/{slug}.html' |
| 179 | |
| 180 | # The location to save the tag page. |
| 181 | TAG_SAVE_AS = 'tag/{slug}.html' |
| 182 | |
| 183 | # The URL to use for an author. |
| 184 | AUTHOR_URL = 'author/{slug}.html' |
| 185 | |
| 186 | # The location to save an author. |
| 187 | AUTHOR_SAVE_AS = 'author/{slug}.html' |
| 188 | |
| 189 | # The location to save per-year archives of your posts. |
| 190 | YEAR_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. |
| 194 | YEAR_ARCHIVE_URL = '' |
| 195 | |
| 196 | # The location to save per-month archives of your posts. |
| 197 | MONTH_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. |
| 201 | MONTH_ARCHIVE_URL = '' |
| 202 | |
| 203 | # The location to save per-day archives of your posts. |
| 204 | DAY_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. |
| 208 | DAY_ARCHIVE_URL = '' |
| 209 | |
| 210 | # Gallery plugin |
luigi | 14ab4f8 | 2020-04-04 22:06:26 +0100 | [diff] [blame] | 211 | PHOTO_LIBRARY = os.getenv('PELICAN_PHOTO_LIBRARY') |
| 212 | PHOTO_EXCLUDE = os.getenv('PELICAN_PHOTO_EXCLUDE') |
| 213 | PHOTO_EXCLUDEALL = os.getenv('PELICAN_PHOTO_EXCLUDEALL') |
Luigi Santivetti | f72f657 | 2020-02-17 23:11:56 +0000 | [diff] [blame] | 214 | PHOTO_GALLERY = (2000, 1333, 100) |
| 215 | PHOTO_ARTICLE = (2000, 1333, 100) |
| 216 | PHOTO_THUMB = (300, 200, 100) |
| 217 | PHOTO_SQUARE_THUMB = False |