From ad38ed291fd5c7585a84413aa89fff756086008b Mon Sep 17 00:00:00 2001
From: Dominik George <nik@naturalnet.de>
Date: Mon, 25 Dec 2017 11:16:25 +0100
Subject: [PATCH] Add basic theme.

---
 content/posts/0001-new-website.markdown |  1 -
 pelicanconf.py                          |  2 ++
 theme/templates/article.html            |  9 +++++++++
 theme/templates/base.html               | 22 ++++++++++++++++++++++
 theme/templates/blog.html               | 14 ++++++++++++++
 5 files changed, 47 insertions(+), 1 deletion(-)
 create mode 100644 theme/templates/article.html
 create mode 100644 theme/templates/base.html
 create mode 100644 theme/templates/blog.html

diff --git a/content/posts/0001-new-website.markdown b/content/posts/0001-new-website.markdown
index b3857fc..331010b 100644
--- a/content/posts/0001-new-website.markdown
+++ b/content/posts/0001-new-website.markdown
@@ -1,5 +1,4 @@
 title: Neue Website in Arbeit
-slug: neue-website-in-arbeit
 category: private
 date: 2017-12-25
 modified: 2017-12-25
diff --git a/pelicanconf.py b/pelicanconf.py
index d9a49e5..50d5a19 100644
--- a/pelicanconf.py
+++ b/pelicanconf.py
@@ -7,6 +7,7 @@ SITENAME = u'Dominik George'
 SITEURL = ''
 
 PATH = 'content'
+STATIC_PATHS = ['static']
 
 TIMEZONE = 'Europe/Berlin'
 
@@ -31,6 +32,7 @@ SOCIAL = (('XMPP / Jabber', 'xmpp:nik@mercurius.teckids.org'),
           ('Twitter', 'https://www.twitter.com/Natureshadow'),)
 
 DEFAULT_PAGINATION = 10
+SLUGIFY_SOURCE = 'title'
 
 # Uncomment following line if you want document-relative URLs when developing
 #RELATIVE_URLS = True
diff --git a/theme/templates/article.html b/theme/templates/article.html
new file mode 100644
index 0000000..be99b65
--- /dev/null
+++ b/theme/templates/article.html
@@ -0,0 +1,9 @@
+{% extends "base.html" %}
+
+{% block title %}{{ article.title }}{% endblock %}
+
+{% block content %}
+ <h2>{{ article.title }}</h2>
+ <label>Veröffentlicht am <strong>{{ article.date }}</strong></label>
+ {{ article.content }}
+{% endblock %}
diff --git a/theme/templates/base.html b/theme/templates/base.html
new file mode 100644
index 0000000..dd9e91f
--- /dev/null
+++ b/theme/templates/base.html
@@ -0,0 +1,22 @@
+<!DOCTYPE html>
+<html lang="de">
+<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <title>{% block title %}{% endblock %}</title>
+</head>
+<body>
+ <div class="container">
+  <div id="header">
+   <h1 id="pagetitle">Dominik George</h1>
+   <p id="subtitle">Free Software Fellow, Education Enthusiast, sozialliberal</p>
+  </div>
+  <div id="menu">
+  </div>
+  <div id="page">
+   {% block content %}{% endblock %}
+  </div>
+  <div id="footer">
+  </div>
+ </div> 
+</body>
+</html>
diff --git a/theme/templates/blog.html b/theme/templates/blog.html
new file mode 100644
index 0000000..983764f
--- /dev/null
+++ b/theme/templates/blog.html
@@ -0,0 +1,14 @@
+{% extends "base.html" %}
+
+{% block title %}{{ SITENAME }}{% endblock %}
+
+{% block content %}
+<h2>Blog</h2>
+{% for article in articles %}
+ <h3><a href="/{{ article.slug }}.html">{{ article.title }}</a></h3>
+ <label>Veröffentlicht am <strong>{{ article.date }}</strong></label>
+ {{ article.content|truncate(110) }}
+{% else %}
+ No posts yet!
+{% endfor %}
+{% endblock %}
-- 
GitLab