summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--content/2023/mastodon-activity-pub.md (renamed from content/blog/2023/mastodon-activity-pub.md)2
-rw-r--r--content/2023/rocking-portale-music-like-its-2005.md (renamed from content/blog/2023/rocking-portale-music-like-its-2005.md)2
-rw-r--r--content/blog/2022/_index.md9
-rw-r--r--content/blog/_index.md9
-rw-r--r--content/toc.md2
-rw-r--r--layouts/_default/index.html18
-rw-r--r--layouts/_default/list.html16
-rw-r--r--layouts/partials/article_list_full_item.html13
-rw-r--r--layouts/partials/back_nav.html2
-rw-r--r--layouts/partials/blog_index.html19
-rw-r--r--static/style.css18
11 files changed, 94 insertions, 16 deletions
diff --git a/content/blog/2023/mastodon-activity-pub.md b/content/2023/mastodon-activity-pub.md
index d65dff5..c479325 100644
--- a/content/blog/2023/mastodon-activity-pub.md
+++ b/content/2023/mastodon-activity-pub.md
@@ -1,7 +1,7 @@
---
title: "Mastodon and ActivityPub"
category:
-- blog
+- article
abstract: Digging into Mastodon and Activity Pub
date: 2023-06-09T21:16:39+02:00
year:
diff --git a/content/blog/2023/rocking-portale-music-like-its-2005.md b/content/2023/rocking-portale-music-like-its-2005.md
index de1859c..a0c9165 100644
--- a/content/blog/2023/rocking-portale-music-like-its-2005.md
+++ b/content/2023/rocking-portale-music-like-its-2005.md
@@ -1,7 +1,7 @@
---
title: "Rocking Portale Music Like Its 2005"
category:
-- blog
+- article
abstract: I have upgraded my setup to cheap mp3 player and wired headphones
date: 2023-03-27T22:09:47+02:00
year: 2023
diff --git a/content/blog/2022/_index.md b/content/blog/2022/_index.md
new file mode 100644
index 0000000..e88d651
--- /dev/null
+++ b/content/blog/2022/_index.md
@@ -0,0 +1,9 @@
+---
+title: "Michal's Sapka Webpage"
+date: 2022-12-28T23:42:51+01:00
+draft: false
+tags: []
+category: msw
+noback: true
+---
+
diff --git a/content/blog/_index.md b/content/blog/_index.md
new file mode 100644
index 0000000..5c902f1
--- /dev/null
+++ b/content/blog/_index.md
@@ -0,0 +1,9 @@
+---
+title: "Michal's Blog"
+category:
+- blog
+abstract:
+date: 2023-12-05T21:27:39+01:00
+draft: false
+---
+
diff --git a/content/toc.md b/content/toc.md
index 9e5be8a..6df4a13 100644
--- a/content/toc.md
+++ b/content/toc.md
@@ -7,7 +7,7 @@ date: 2023-11-17T20:42:09+01:00
draft: false
hardback: true
---
-This is lost of all pages on my website.
+This is a list of all pages on my website.
I think it's better to go into individual sections to explore, but this also exists.
{{<toc>}}
diff --git a/layouts/_default/index.html b/layouts/_default/index.html
index 2770e36..008a958 100644
--- a/layouts/_default/index.html
+++ b/layouts/_default/index.html
@@ -10,14 +10,22 @@ Hey! I'm Michał Sapka, a computer programmer living in Kraków, Poland. This we
{{ end }}
<p><a href="/all_updates">&raquo; All updates</a></p>
+<h2>Recent blog posts</h2>
+
+{{ $recent_categories := slice "blog" }}
+{{ range first 7 (where .Site.RegularPages ".Params.category" "intersect" $recent_categories) }}
+ {{ partial "partials/article_list_item.html" . }}
+{{ end }}
+<p><a href="/blog/">&raquo; Go to blog</a></p>
<h2>Sections</h2>
<nav>
- <P> &#10022; <a class="sec-link" href="/bsd/"><b>BSD site</b>: my writings on Berkley Standard Distribution flabors. OSes I use at the daily basis.</a> </p>
- <P> &#10022; <a class="sec-link" href="/star-trek/"><b>Star Trek fan site</b>: my little shrine to the greatest american Sci-Fi that has ever graced our screens.</a> </p>
- <P> &spades; <a class="sec-link" href="/funnies/"><b>Funnies</b>: A small, curated collection of things I found funny or ammusing.</a> </p>
- <p> &#9851; <a class="sec-link" href="/vcs/git/"><b>Version control system</b> : My little code repository. I don't expect to cooporate on any of those, so it's just stagit.</a></p>
- <p> &#x2665; <a class="sec-link" href="/site/"><b>Site info</b> : you can find site uptates, metrics, statics, and legal thingies here.</a></p>
+ <P><a class="sec-link" href="/blog/"><b>Blog</b>: my shorter publications withount any theme. You can treat it as E/N site.</a> </p>
+ <P><a class="sec-link" href="/bsd/"><b>BSD site</b>: my writings on Berkley Standard Distribution flabors. OSes I use at the daily basis.</a> </p>
+ <P><a class="sec-link" href="/star-trek/"><b>Star Trek fan site</b>: my little shrine to the greatest american Sci-Fi that has ever graced our screens.</a> </p>
+ <P><a class="sec-link" href="/funnies/"><b>Funnies</b>: A small, curated collection of things I found funny or ammusing.</a> </p>
+ <p><a class="sec-link" href="/vcs/git/"><b>Version control system</b> : My little code repository. I don't expect to cooporate on any of those, so it's just stagit.</a></p>
+ <p><a class="sec-link" href="/site/"><b>Site info</b> : you can find site uptates, metrics, statics, and legal thingies here.</a></p>
</nav>
<h2>TOC</h2>
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index ae89782..f1fd111 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -1,11 +1,13 @@
{{ define "main" }}
- <h2>
- {{ replace .Title "-" " " }} archives
- </h2>
- <h3>Articles</h3>
- {{ range .Data.Pages }}
- {{ partial "partials/article_list_item.html" . }}
- {{ end }}
+ {{ if in .Page.Params.Category "blog" }}
+ {{ partial "partials/blog_index.html" . }}
+ {{ else }}
+
+ <h2>Articles</h2>
+ {{ range .Data.Pages }}
+ {{ partial "partials/article_list_item.html" . }}
+ {{ end }}
+ {{ end }}
{{ end }}
diff --git a/layouts/partials/article_list_full_item.html b/layouts/partials/article_list_full_item.html
new file mode 100644
index 0000000..31ab76f
--- /dev/null
+++ b/layouts/partials/article_list_full_item.html
@@ -0,0 +1,13 @@
+<article class="blog-post-item">
+ <h2> <a href="{{ .Page.Permalink }}"> {{ .Title }}</a></h2>
+
+ <time datetime="{{.PublishDate.Format "2006-01-02" }}">
+ {{ .PublishDate.Format "January 2, 2006" }}
+ </time>
+
+ <nav>
+ <a href="{{ .Page.Permalink }}">[ Permalink ]</a>
+ </nav>
+
+ {{ .Page.Content }}
+</article>
diff --git a/layouts/partials/back_nav.html b/layouts/partials/back_nav.html
index 9f7620f..6358a10 100644
--- a/layouts/partials/back_nav.html
+++ b/layouts/partials/back_nav.html
@@ -9,7 +9,7 @@
{{ else if in .Page.Params.Category "bsd" }}
<a href="/bsd/">&larr; Back to Daemonic BSD Site</a>
{{ else if in .Page.Params.Category "blog" }}
- <a href="/bsd/">&larr; Back to Michal's blog</a>
+ <a href="/blog/">&larr; Back to Michal's blog</a>
{{ end }}
{{ if not .Page.Params.hardback }}
diff --git a/layouts/partials/blog_index.html b/layouts/partials/blog_index.html
new file mode 100644
index 0000000..81768b7
--- /dev/null
+++ b/layouts/partials/blog_index.html
@@ -0,0 +1,19 @@
+{{ $paginator := .Paginator 25 }}
+{{ range (.Paginate (where .Site.RegularPages ".Params.category" "intersect" "blog")).Pages }}
+ {{ partial "partials/article_list_full_item.html" . }}
+{{ end }}
+
+<nav class="blog-pages-list">
+ Pages:
+ {{ if $paginator.HasPrev }}
+ [ <a href="{{ $paginator.First.URL}}">previous</a> ]
+ {{ end }}
+
+ {{ range seq $paginator.TotalPages }}
+ <a href="/blog/page/{{ . }}/">{{ . }}</a>
+ {{ end }}
+
+ {{ if $paginator.HasNext }}
+ [ <a href="{{ $paginator.Next.URL}}">Next</a> ]
+ {{ end }}
+</nav>
diff --git a/static/style.css b/static/style.css
index ec5c2e5..e956d07 100644
--- a/static/style.css
+++ b/static/style.css
@@ -217,6 +217,24 @@ body.blog h1 {
}
/* blog_header_end */
+/* blog_post_list_start */
+article.blog-post-item > h2 > a {
+ text-decoration: none;
+}
+article.blog-post-item > nav {
+ display: inline-block;
+}
+article.blog-post-item > nav > a {
+ text-decoration: none;
+}
+nav.blog-pages-list {
+ margin-bottom: 20px;
+}
+nav.blog-pages-list a {
+ text-decoration: underline;
+}
+/* blog_post_list_end */
+
/* legacy_code_start */
/* ---------- Main */