This repository has been archived by the owner on Jan 3, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
/
pelicanconf.py
135 lines (122 loc) · 3.52 KB
/
pelicanconf.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
# -*- coding: utf-8 -*- #
from __future__ import unicode_literals
AUTHOR = u'CCC-CH'
SITENAME = u'CCC-CH'
SITEURL = u'https://www.ccc-ch.ch'
TIMEZONE = u'Europe/Zurich'
DEFAULT_LANG = u'de'
DEFAULT_DATE_FORMAT = '%a %d. %B %Y'
# Page path
PAGE_PATHS = ['pages']
# Menu
MENUITEMS = (
('Home', 'index.html', None),
('CCC-CH', '#', [
('FAQ', 'faq.html'),
('Statuten', 'statuten.html'),
('Mitglieder', 'members.html'),
('Pressereaktionen', 'category_pressreview.html'),
]),
('Medienmitteilungen', 'category_medien.html', None),
('Intern', '#', [
('Protokolle', 'protokolle.html'),
('Mitgliederbeiträge', 'mitgliederbeitraege.html'),
('Gettogether', 'gettogether.html'),
('Schleuder', 'schleuder.html'),
]),
)
I18N_SUBSITES = {
'de': {
'LOCALE': "de_CH.UTF-8",
'STATIC_PATHS': [
'files'
],
'MENUITEMS': MENUITEMS,
},
'fr': {
'LOCALE': "fr_CH.UTF-8",
'STATIC_PATHS': [
'files'
],
'MENUITEMS': [
('Home', 'index.html', None),
('CCC-CH', '#', [
('Statuts', 'statuten.html'),
]),
],
},
'it': {
'LOCALE': "it_CH.UTF-8",
'STATIC_PATHS': [
'files'
],
'MENUITEMS': [
('Home', 'index.html', None),
('CCC-CH', '#', [
('Statuti', 'statuten.html'),
]),
],
},
'en': {
'LOCALE': "en_GB.UTF-8",
'STATIC_PATHS': [
'files'
],
'MENUITEMS': [
('Home', 'index.html', None),
('Press releases', 'category_media.html', None),
],
}
}
# Sole author and don't use categories ... disable these features
#AUTHOR_SAVE_AS = ''
#AUTHORS_SAVE_AS = ''
#CATEGORY_SAVE_AS = ''
#CATEGORIES_SAVE_AS = ''
# don't show categories and pages in the menu
DISPLAY_PAGES_ON_MENU = False
DISPLAY_CATEGORIES_ON_MENU = False
# Feed generation is usually not desired when developing
FEED_ALL_RSS = None
FEED_ALL_ATOM = None
FEED_RSS = 'feeds/rss.xml'
FEED_ATOM = 'feeds/atom.xml'
CATEGORY_FEED_ATOM = 'feeds/atom_%s.xml'
CATEGORY_FEED_RSS = 'feeds/rss_%s.xml'
TRANSLATION_FEED_ATOM = None
AUTHOR_FEED_ATOM = None
AUTHOR_FEED_RSS = None
# URL settings
# Uncomment following line if you want document-relative URLs when developing
RELATIVE_URLS = True
ARTICLE_URL = '{slug}.html'
PAGE_URL = '{slug}.html'
PAGE_SAVE_AS = '{slug}.html'
TAG_URL = 'tag-{slug}.html'
TAG_SAVE_AS = 'tag-{slug}.html'
TAGS_URL = 'tags.html'
TAGS_SAVE_AS = 'tags.html'
ARCHIVES_URL = 'archives.html'
ARCHIVES_SAVE_AS = 'archives.html'
CATEGORY_URL = 'category_{slug}.html'
CATEGORY_SAVE_AS = 'category_{slug}.html'
# Contact
EMAIL_ADDR = '[email protected]'
# Plugins
PLUGIN_PATHS = ['plugins']
PLUGINS = ['i18n_subsites']
# Theme
THEME = 'theme'
STATIC_PATHS = ['images', 'media', 'articles', 'docs', 'extra/robots.txt', 'extra/favicon.ico', 'extra/htaccess']
PATH_METADATA = 'pages/(?P<path>.*)\..*'
EXTRA_PATH_METADATA = {
'extra/robots.txt': {'path': 'robots.txt'},
'extra/favicon.ico': {'path': 'favicon.ico'},
'extra/htaccess': {'path': '.htaccess'},
}
# Licence
LICENCE_NAME = 'BY-NC-SA'
LICENCE_URL = 'http://creativecommons.org/licenses/by-nc-sa/3.0/deed.en_US'
LICENCE_URL_IMG = 'http://i.creativecommons.org/l/by-nc-sa/3.0/80x15.png'
# Tag cloud
TAG_CLOUD_STEPS = 4