nikola init mysiteBlue
1) Folder images (containg images to be used in the website) placed in mysite/galleries/images
2) Edit file conf.py:
POSTS = ()
PAGES = (
("stories/*.rst", "", "story.tmpl"),
("stories/*.txt", "", "story.tmpl"),
("stories/*.html", "", "story.tmpl"),
)
INDEX_PATH = "blog"
3) Create first page (index):
nikola new_page
4) Theme:
nikola bootswatch_theme -s lumen
# update file conf.py
THEME = "custom"
5) Add blog
# update file conf.py
POSTS = (
("posts/*.rst", "blog", "post.tmpl"),
("posts/*.txt", "blog", "post.tmpl"),
("posts/*.html", "blog", "post.tmpl"),
)
# create first post
nikola new_post
# update Navigation in file conf.py
NAVIGATION_LINKS = {
DEFAULT_LANG: (
("/archive.html", "Archive"),
("/categories/", "Tags"),
("/blog/", "News"),
),
}
6) Add image logo
Add logo.jpg to themes/custom/assets/img/
LOGO_URL = '/assets/img/logo.jpg'
SHOW_BLOG_TITLE = False
IPython Notebook/Jupyter
Edit file conf.py:
POSTS = (
("posts/*.rst", "blog", "post.tmpl"),
("posts/*.txt", "blog", "post.tmpl"),
("posts/*.html", "blog", "post.tmpl"),
("posts/*.ipynb", "blog", "post.tmpl"),
)
PAGES = (
("stories/*.rst", "", "story.tmpl"),
("stories/*.txt", "", "story.tmpl"),
("stories/*.html", "", "story.tmpl"),
("stories/*.ipynb", "", "story.tmpl"),
)
FILES_FOLDERS = {'files': 'files'}
.. title: Welcome!
.. slug: index
.. date: 2016-08-02 15:53:13 UTC+01:00
.. tags:
.. category:
.. link:
.. description:
.. type: text
.. class:: jumbotron
.. image:: galleries/images/mywordcloud.png
Navigation bar
NAVIGATION_LINKS = {
DEFAULT_LANG: (
("/blog", "News"),
("/highlights/", "Highlights"),
("/research/", "Research"),
("/publications/", "Publications"),
("/archive.html", "Archive"),
("/contacts/", "Contacts"),
),
}
Text to link <URL>
_