-
Notifications
You must be signed in to change notification settings - Fork 204
/
Copy pathpelicanconf.py
117 lines (92 loc) · 3.27 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
#!/usr/bin/env python
# -*- coding: utf-8 -*- #
import os
AUTHOR = u'Thomas Wiecki'
SITENAME = u'While My MCMC Gently Samples'
SITESUBTITLE = """Bayesian modeling, Data Science, and Python"""
SITEURL = 'https://twiecki.io'
#SITEURL = 'http://localhost:8000'
TIMEZONE = 'USA/NYC'
# Times and dates
DEFAULT_DATE_FORMAT = '%b %d, %Y'
TIMEZONE = 'US/Eastern'
DEFAULT_LANG = u'en'
# Set the article URL
ARTICLE_URL = 'blog/{date:%Y}/{date:%m}/{date:%d}/{slug}/'
ARTICLE_SAVE_AS = 'blog/{date:%Y}/{date:%m}/{date:%d}/{slug}/index.html'
DISPLAY_CATEGORIES_ON_MENU = False
DISPLAY_PAGES_ON_MENU = False
# Title menu options
MENUITEMS = (
('Consulting', 'https://www.pymc-labs.io'),
('Intuitive Bayesian Guide', '/pages/an-intuitive-guide-to-bayesian-statistics.html'),
#('Consulting', '/pages/consulting.html'),
#('Workshops', '/pages/workshops.html'),
('Podcast', 'http://pydata-podcast.com'),
#('Email', 'https://spamty.eu/show/v5/75/xDU3fnp6wdoZgiWHKw/'),
('Archive', '/archives.html'),
)
NEWEST_FIRST_ARCHIVES = False
#Github include settings
#GITHUB_USER = 'twiecki'
#GITHUB_REPO_COUNT = 3
#GITHUB_SKIP_FORK = True
#GITHUB_SHOW_USER_LINK = True
# Blogroll
#LINKS = (('Pelican', 'http://docs.notmyidea.org/alexis/pelican/'),
# ('Python.org', 'http://python.org'),
# ('Jinja2', 'http://jinja.pocoo.org'),
# ('You can modify those links in your config file', '#'),)
# Social widget
#SOCIAL = (('You can add links in your config file', '#'),
# ('Another social link', '#'),)
DEFAULT_PAGINATION = 10
# STATIC_OUT_DIR requires https://github.com/jakevdp/pelican/tree/specify-static
#STATIC_OUT_DIR = ''
#STATIC_PATHS = ['images', 'figures', 'downloads']
#FILES_TO_COPY = [('favicon.png', 'favicon.png')]
# This requires Pelican 3.3+
STATIC_PATHS = ['images', 'figures', 'downloads', 'favicon.png']
CODE_DIR = 'downloads/code'
NOTEBOOK_DIR = 'downloads/notebooks'
MARKUP = ("md", "ipynb")
from pelican_jupyter import markup as nb_markup
IGNORE_FILES = [".ipynb_checkpoints"]
# Theme and plugins
THEME = 'pelican-octopress-theme'
PLUGIN_PATHS = ['pelican-plugins']
PLUGINS = ['summary', 'liquid_tags.img', 'liquid_tags.video',
'liquid_tags.include_code', nb_markup, 'render_math',
'liquid_tags.literal', 'i18n_subsites']
DISPLAY_PAGES_ON_MENU = False
JINJA_ENVIRONMENT = {'extensions': ['jinja2.ext.i18n']}
CATEGORY_SAVE_AS = ''
TAGS_SAVE_AS = ''
# The theme file should be updated so that the base header contains the line:
#
# {% if EXTRA_HEADER %}
# {{ EXTRA_HEADER }}
# {% endif %}
#
# This header file is automatically generated by the notebook plugin
if not os.path.exists('_nb_header.html'):
import warnings
warnings.warn("_nb_header.html not found. "
"Rerun make html to finalize build.")
else:
EXTRA_HEADER = open('_nb_header.html').read() #.decode('utf-8')
# Sharing
TWITTER_USER = 'twiecki'
FACEBOOK_LIKE = False
TWITTER_TWEET_BUTTON = True
TWITTER_LATEST_TWEETS = True
TWITTER_FOLLOW_BUTTON = True
TWITTER_TWEET_COUNT = 3
TWITTER_SHOW_REPLIES = 'false'
TWITTER_SHOW_FOLLOWER_COUNT = 'true'
# RSS/Atom feeds
FEED_DOMAIN = SITEURL
FEED_ATOM = 'atom.xml'
# Search
SEARCH_BOX = False
SITESEARCH = 'https://google.com/search'