From cea3e75c68070d180311f6dea56c192a7f90c23d Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Wed, 19 Apr 2023 14:06:56 +0200 Subject: Switch to bear blog theme --- config.toml | 21 ++++---- templates/footer.html | 1 + templates/index.html | 39 +++++++++++++++ themes/bear | 2 +- themes/xmin/static/css/style.css | 75 ---------------------------- themes/xmin/templates/base.html | 25 ---------- themes/xmin/templates/categories/list.html | 1 - themes/xmin/templates/categories/single.html | 1 - themes/xmin/templates/index.html | 36 ------------- themes/xmin/templates/page.html | 28 ----------- themes/xmin/templates/section.html | 18 ------- themes/xmin/templates/tags/list.html | 18 ------- themes/xmin/templates/tags/single.html | 25 ---------- themes/xmin/theme.toml | 12 ----- 14 files changed, 50 insertions(+), 252 deletions(-) create mode 100644 templates/footer.html create mode 100644 templates/index.html delete mode 100644 themes/xmin/static/css/style.css delete mode 100644 themes/xmin/templates/base.html delete mode 120000 themes/xmin/templates/categories/list.html delete mode 120000 themes/xmin/templates/categories/single.html delete mode 100644 themes/xmin/templates/index.html delete mode 100644 themes/xmin/templates/page.html delete mode 100644 themes/xmin/templates/section.html delete mode 100644 themes/xmin/templates/tags/list.html delete mode 100644 themes/xmin/templates/tags/single.html delete mode 100644 themes/xmin/theme.toml diff --git a/config.toml b/config.toml index aeafa11..840625f 100644 --- a/config.toml +++ b/config.toml @@ -9,7 +9,7 @@ description = "Developer, Emacs User" generate_feed = true -theme = "xmin" +theme = "bear" [markdown] highlight_code = true @@ -20,33 +20,30 @@ name = "tags" feed = true [extra] -footer = "Licensed under a Creative Commons Attribution 4.0 International License." gpg_fingerprint = "48E6 576C 0707 388C B8BE FD0C CD4B EB92 A8D4 6583" gpg_url = "/public_key.asc" author_name = "Alan Pearce" author_image = "/img/me-thumb.jpg" +hide_made_with_line = true +date_format = "%F" -[[extra.menu.main]] - name = "Home" - url = "/" - weight = 1 -[[extra.menu.main]] +[[extra.main_menu]] name = "Posts" url = "/post/" -[[extra.menu.main]] +[[extra.main_menu]] name = "Tags" url = "/tags/" -[[extra.menu.main]] +[[extra.main_menu]] name = "Repositories" url = "https://git.alanpearce.eu" -[[extra.menu.contact]] +[[extra.contact_menu]] name = "alan@alanpearce.eu" url = "mailto:alan@alanpearce.eu" weight = 1 -[[extra.menu.contact]] +[[extra.contact_menu]] name = "Codeberg" url = "https://codeberg.org/alanpearce" -[[extra.menu.contact]] +[[extra.contact_menu]] name = "GitHub" url = "https://github.com/alanpearce" diff --git a/templates/footer.html b/templates/footer.html new file mode 100644 index 0000000..d66241b --- /dev/null +++ b/templates/footer.html @@ -0,0 +1 @@ +Licensed under a Creative Commons Attribution 4.0 International License. diff --git a/templates/index.html b/templates/index.html new file mode 100644 index 0000000..10465a4 --- /dev/null +++ b/templates/index.html @@ -0,0 +1,39 @@ +{% extends "base.html" %} + +{% block body_attrs %} class="h-card vcard"{% endblock %} + +{% block title_class %} p-name fn{% endblock %} + +{% block main %} + + {{ section.content | safe }} + +
+

Latest Posts

+ +
+
+

Elsewhere on the Internet

+ +
+ +{% endblock %} diff --git a/themes/bear b/themes/bear index c78a3f2..6687460 160000 --- a/themes/bear +++ b/themes/bear @@ -1 +1 @@ -Subproject commit c78a3f2301caa3dc4c03d3b2a75f4f003e5863d0 +Subproject commit 66874604ae503ee450c056817478f92b7d446cd0 diff --git a/themes/xmin/static/css/style.css b/themes/xmin/static/css/style.css deleted file mode 100644 index e605297..0000000 --- a/themes/xmin/static/css/style.css +++ /dev/null @@ -1,75 +0,0 @@ -body { - font-family: sans-serif; - line-height: 1.5em; - margin: auto; - max-width: 800px; - padding: 1em; -} - -/* header and footer areas */ -nav > ul { padding: 0; } -nav > ul > li { display: inline-block; } -article > header, nav > ul a { - background: #eee; - border-radius: 5px; - padding: 5px; - text-decoration: none; -} -.terms { font-size: .9em; } -nav > ul, article > header, footer { text-align: center; } -.title { font-size: 1.1em; } -footer a { text-decoration: none; } -hr { - border-style: dashed; - color: #ddd; -} -body > nav { - border-bottom: 1px solid #ddd; -} -body > footer { - border-top: 1px solid #ddd; -} - -/* code */ -pre { - border: 1px solid #ddd; - overflow-x: auto; - padding: 1em; -} -code { background: #f9f9f9; } -pre code { background: none; } - -/* misc elements */ -img, iframe, video { max-width: 100%; } -main { hyphens: auto; } -blockquote { - background: #f9f9f9; - border-left: 5px solid #ccc; - padding: 3px 1em 3px; -} - -table thead th { border-bottom: 1px solid #ddd; } -th, td { padding: 5px; } -thead, tfoot, tr:nth-child(even) { background: #eee; } -.hl { background-color: #ffc; } - -@media (prefers-color-scheme: dark) { - body { - background-color: #111; - color: white; - } - article > header, nav > ul a { - background: #222; - } - a { - color: #C4D4EE; - } - a:visited { - color: #CEDEE0; - } - code { background-color: #444; } - thead, tfoot, tr:nth-child(even) { background: #222; } - .hl { - background-color: #555; - } -} diff --git a/themes/xmin/templates/base.html b/themes/xmin/templates/base.html deleted file mode 100644 index 5942342..0000000 --- a/themes/xmin/templates/base.html +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - {% block title %}{{ section.title }} | {{ config.title }}{% endblock %} - - {%- if config.generate_feed %} - {%- block rss %} - - {%- endblock %} - {%- endif %} - - - - {% block main %}{% endblock %} - - - diff --git a/themes/xmin/templates/categories/list.html b/themes/xmin/templates/categories/list.html deleted file mode 120000 index e0e4e08..0000000 --- a/themes/xmin/templates/categories/list.html +++ /dev/null @@ -1 +0,0 @@ -../tags/list.html \ No newline at end of file diff --git a/themes/xmin/templates/categories/single.html b/themes/xmin/templates/categories/single.html deleted file mode 120000 index 86f5e80..0000000 --- a/themes/xmin/templates/categories/single.html +++ /dev/null @@ -1 +0,0 @@ -../tags/single.html \ No newline at end of file diff --git a/themes/xmin/templates/index.html b/themes/xmin/templates/index.html deleted file mode 100644 index 23ec4cd..0000000 --- a/themes/xmin/templates/index.html +++ /dev/null @@ -1,36 +0,0 @@ -{% extends "base.html" %} - -{% block main %} -
-

{{ config.title }}

- {{ section.content | safe }} -
-

Latest Posts

- -
-
-

Elsewhere on the Internet

- -
- -
-{% endblock %} diff --git a/themes/xmin/templates/page.html b/themes/xmin/templates/page.html deleted file mode 100644 index f32a6fc..0000000 --- a/themes/xmin/templates/page.html +++ /dev/null @@ -1,28 +0,0 @@ -{% extends "base.html" %} - -{% block title %} -{{- page.title -}} -{% endblock %} - -{% block main %} -
-
-

{{ page.title }}

- -

- {%- if page.taxonomies %} - {%- for name, taxon in page.taxonomies %} - {{ name | capitalize }}: - {%- for item in taxon %} - {{ item }} - {%- endfor %} - {%- endfor %} - {%- endif %} -

-
- -
- {{ page.content | safe }} -
-
-{% endblock %} diff --git a/themes/xmin/templates/section.html b/themes/xmin/templates/section.html deleted file mode 100644 index e61566f..0000000 --- a/themes/xmin/templates/section.html +++ /dev/null @@ -1,18 +0,0 @@ -{% extends "base.html" %} - -{% block main %} -
-

{{ section.title }}

- {{ section.content }} -
- -
-
-{% endblock %} diff --git a/themes/xmin/templates/tags/list.html b/themes/xmin/templates/tags/list.html deleted file mode 100644 index ee60c39..0000000 --- a/themes/xmin/templates/tags/list.html +++ /dev/null @@ -1,18 +0,0 @@ -{% extends "base.html" %} - -{% block title %}{{ taxonomy.name | capitalize }}{% endblock %} - -{% block main %} -
-

{{ taxonomy.name | capitalize }}

-
- -
-
-{% endblock %} diff --git a/themes/xmin/templates/tags/single.html b/themes/xmin/templates/tags/single.html deleted file mode 100644 index 25dde54..0000000 --- a/themes/xmin/templates/tags/single.html +++ /dev/null @@ -1,25 +0,0 @@ -{% extends "base.html" %} - -{% block rss %} - {% set rss_path = "tags/" ~ term.name ~ "/atom.xml" %} - - -{% endblock %} - -{% block title %}{{ taxonomy.name | capitalize }}: {{ term.name }} | {{ config.title }}{% endblock %} - -{% block main %} -
-

{{ taxonomy.name | capitalize }}: {{ term.name }}

-
- -
-
-{% endblock %} diff --git a/themes/xmin/theme.toml b/themes/xmin/theme.toml deleted file mode 100644 index 99884b9..0000000 --- a/themes/xmin/theme.toml +++ /dev/null @@ -1,12 +0,0 @@ -name = "xmin" -description = "XMin is a Hugo theme written by Yihui Xie in about four hours" -license = "MIT" - -[author] -name = "Alan Pearce" -homepage = "https://www.alanpearce.eu" - -[original] -author = "yihui" -homepage = "https://yihui.org" -repo = "https://github.com/yihui/hugo-xmin" \ No newline at end of file -- cgit 1.4.1