diff --git a/config.toml b/config.toml index b15461c..d0b1eb4 100644 --- a/config.toml +++ b/config.toml @@ -19,6 +19,6 @@ nav_items = [ {name="Home", path="/"}, {name="About", path="/about"}, {name="Projects", path="/projects/"}, - #{name="Posts", path="/posts"} + {name="Posts", path="/posts"} ] diff --git a/content/posts/_index.md b/content/posts/_index.md new file mode 100644 index 0000000..2af08ed --- /dev/null +++ b/content/posts/_index.md @@ -0,0 +1,7 @@ ++++ +title = "Posts" +template = "post_list.html" +page_template = "post.html" +sort_by = "date" ++++ + diff --git a/content/posts/jellyfin.md b/content/posts/jellyfin.md new file mode 100644 index 0000000..c9e5dd3 --- /dev/null +++ b/content/posts/jellyfin.md @@ -0,0 +1,9 @@ ++++ +title = "Jellyfin" +date = 2024-10-03 +description = "My Jellyfin docker based instance" ++++ + +This is an post about my docker based Jellyfin instance + + diff --git a/content/posts/nextcloud.md b/content/posts/nextcloud.md new file mode 100644 index 0000000..02f3799 --- /dev/null +++ b/content/posts/nextcloud.md @@ -0,0 +1,9 @@ ++++ +title = "Nextcloud" +date = 2024-10-03 +description = "My Nextcloud docker based instance" ++++ + +This is an post about my docker based Nextcloud instance + + diff --git a/templates/post.html b/templates/post.html new file mode 100644 index 0000000..91bdb80 --- /dev/null +++ b/templates/post.html @@ -0,0 +1,26 @@ +{% extends "base.html" %} + +{% block styles %} + +{% endblock styles %} + +{% block content %} + + + + {{ page.title }} + + {{ page.content | safe }} + + Back to list of posts + +{% endblock content %} + diff --git a/templates/post_list.html b/templates/post_list.html new file mode 100644 index 0000000..471484c --- /dev/null +++ b/templates/post_list.html @@ -0,0 +1,28 @@ +{% extends "base.html" %} + +{% block styles %} + +{% endblock styles %} + +{% block content %} + + My Posts + {% for post in section.pages %} + + + {{ post.title }} + + + {% if post.description %} + {{ post.description }} + {% else %} + … + {% endif %} + + + {{ post.date }} + + {% endfor %} + +{% endblock content %} +
+ {% if post.description %} + {{ post.description }} + {% else %} + … + {% endif %} +
{{ post.date }}