From 41bd0ad58e44244fe67cb36e066d4bb68738516f Mon Sep 17 00:00:00 2001 From: Christian Cleberg Date: Fri, 29 Mar 2024 01:30:23 -0500 Subject: massive re-write from org-publish to weblorg --- theme/templates/atom.xml | 42 ++++++++++++++++++++++++++++++++++++++++++ theme/templates/base.html | 41 +++++++++++++++++++++++++++++++++++++++++ theme/templates/blog.html | 14 ++++++++++++++ theme/templates/index.html | 41 +++++++++++++++++++++++++++++++++++++++++ theme/templates/page.html | 11 +++++++++++ theme/templates/post.html | 30 ++++++++++++++++++++++++++++++ theme/templates/wiki.html | 17 +++++++++++++++++ 7 files changed, 196 insertions(+) create mode 100644 theme/templates/atom.xml create mode 100644 theme/templates/base.html create mode 100644 theme/templates/blog.html create mode 100644 theme/templates/index.html create mode 100644 theme/templates/page.html create mode 100644 theme/templates/post.html create mode 100644 theme/templates/wiki.html (limited to 'theme/templates') diff --git a/theme/templates/atom.xml b/theme/templates/atom.xml new file mode 100644 index 0000000..8ff1e30 --- /dev/null +++ b/theme/templates/atom.xml @@ -0,0 +1,42 @@ + + + + {{ site_name | default("Simple Blog") }} + + {{ url_for("index") }} + + en + {{ posts | first | getattr("date") | strftime("%a, %d %b %Y %H:%M:%S %z") }} + {{ now() | strftime("%a, %d %b %Y %H:%M:%S %z") }} + {{ meta.generator }} + {{ site_owner | default("hello@cleberg.net") }} + + {{ url_for("index") }}media/img/8bitme.png + Blog Author + {{ url_for("index") }} + + + {% for post in posts %} + + {{ post.title }} + {{ url_for("blog", slug=post.slug) }} + {{ post.author|default("hello@cleberg.net") }} + {{ url_for("blog", slug=post.slug) }} + {{ post.date|strftime("%a, %d %b %Y %H:%M:%S %z") }} + + + {% endfor %} + + + diff --git a/theme/templates/base.html b/theme/templates/base.html new file mode 100644 index 0000000..167883c --- /dev/null +++ b/theme/templates/base.html @@ -0,0 +1,41 @@ + + + + + {% block head %} + + + {% block subtitle %}{% endblock %} + {% block title %}{{ site_name | default("weblorg website") }}{% endblock %} + + + {% if site_owner is defined %}{% endif %} + {% if site_description is defined %}{% endif %} + {% if site_keywords is defined %}{% endif %} + + {% block meta %}{% endblock %} + {% endblock %} + + + {% block nav %} + + {% endblock %} + +
{% block main %}{% endblock %}
+ + {% block footer %} + + {% endblock %} + + diff --git a/theme/templates/blog.html b/theme/templates/blog.html new file mode 100644 index 0000000..b3b3a3f --- /dev/null +++ b/theme/templates/blog.html @@ -0,0 +1,14 @@ +{% extends "base.html" %} + +{% block subtitle %}Blog | {% endblock %} +{% block main %} +

Blog

+

Use Ctrl + F to search blog post titles for keywords.

+

You can also add the RSS Feed to your feed reader.

+ {% for post in posts %} +
+ + {{ post.title }} +
+ {% endfor %} +{% endblock %} diff --git a/theme/templates/index.html b/theme/templates/index.html new file mode 100644 index 0000000..924335c --- /dev/null +++ b/theme/templates/index.html @@ -0,0 +1,41 @@ +{% extends "base.html" %} + +{% block main %} +
+

cleberg.net

+
Do AIs dream in electric sheep?
He hoped it had nanosecond nightmares.
+
+
+

Recent Blog Posts

+
+ + Self-Hosting DDNS Updater +
+
+ + Doom Emacs & Org-Mode +
+
+ + Self-Hosting An Otter Wiki +
+
+ All Posts → +
+
+

Everything Else

+ +
+
+

Contact

+ +
+{% endblock %} diff --git a/theme/templates/page.html b/theme/templates/page.html new file mode 100644 index 0000000..fb7afa9 --- /dev/null +++ b/theme/templates/page.html @@ -0,0 +1,11 @@ +{% extends "base.html" %} + +{% block subtitle %} + {{ post.title }} | +{% endblock %} +{% block main %} +
+

{{ post.title }}

+
{{ post.html | safe }}
+
+{% endblock %} diff --git a/theme/templates/post.html b/theme/templates/post.html new file mode 100644 index 0000000..d0b76db --- /dev/null +++ b/theme/templates/post.html @@ -0,0 +1,30 @@ +{% extends "base.html" %} + +{% block subtitle %} + {{ post.title }} | +{% endblock %} +{% block meta %} + + +{% if post.description is defined %} + +{% elif project_description is defined %} + +{% endif %} + + +{% endblock %} + +{% block main %} +
+ +
+ {{ post.html | safe }} +
+
+{% endblock %} diff --git a/theme/templates/wiki.html b/theme/templates/wiki.html new file mode 100644 index 0000000..3d8b8fd --- /dev/null +++ b/theme/templates/wiki.html @@ -0,0 +1,17 @@ +{% extends "base.html" %} + +{% block subtitle %}Wiki | {% endblock %} +{% block main %} +

Wiki

+

Use Ctrl + F to search wiki pages for keywords.

+
+

Wiki Page

+

Last Updated

+
+{% for post in posts %} +
+ {{ post.title }} + +
+{% endfor %} +{% endblock %} -- cgit v1.2.3-70-g09d2