From e7525403dd6b2b0c01c9c8bdc4f11f97284a776a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sen=CC=83or=20Rolando?= Date: Sun, 17 Nov 2024 17:00:42 +0100 Subject: [PATCH] Update to theme anake v2 and use it as hugo module instead of git submodule --- .gitmodules | 3 -- README.md | 9 ++++- content/_index.md | 1 - go.mod | 5 +++ go.sum | 2 + hugo.toml | 65 ++++++++++++++++++------------- layouts/partials/site-footer.html | 2 +- themes/ananke | 1 - 8 files changed, 55 insertions(+), 33 deletions(-) create mode 100644 go.mod create mode 100644 go.sum delete mode 160000 themes/ananke diff --git a/.gitmodules b/.gitmodules index 5154615..e69de29 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +0,0 @@ -[submodule "themes/ananke"] - path = themes/ananke - url = https://github.com/theNewDynamic/gohugo-theme-ananke.git diff --git a/README.md b/README.md index ca13c2f..b1748f3 100755 --- a/README.md +++ b/README.md @@ -3,7 +3,14 @@ ## Setup ```console -$ git submodule add https://github.com/theNewDynamic/gohugo-theme-ananke.git themes/ananke +$ hugo mod init codeberg.org/sr-rolando/sr-rolando.com +& hugo mod tidy +``` + +In `hugo.toml`: + +```toml +theme = ["github.com/theNewDynamic/gohugo-theme-ananke/v2"] ``` `make`-Targets: diff --git a/content/_index.md b/content/_index.md index 8e46f17..163d4a3 100644 --- a/content/_index.md +++ b/content/_index.md @@ -1,6 +1,5 @@ --- title: "Señor Rolando" - description: "Lesender Läufer." cascade: featured_image: '/image/default-hero-image-objects-d-art.jpg' diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..9e91378 --- /dev/null +++ b/go.mod @@ -0,0 +1,5 @@ +module codeberg.org/sr-rolando/sr-rolando.com + +go 1.23.2 + +require github.com/theNewDynamic/gohugo-theme-ananke/v2 v2.11.2 // indirect diff --git a/go.sum b/go.sum new file mode 100644 index 0000000..584a69c --- /dev/null +++ b/go.sum @@ -0,0 +1,2 @@ +github.com/theNewDynamic/gohugo-theme-ananke/v2 v2.11.2 h1:e57wIClfYebSg7lqJ6ZBbsPaOO+qYEUuqzKbOCwSMqA= +github.com/theNewDynamic/gohugo-theme-ananke/v2 v2.11.2/go.mod h1:PiXJyylwvAMIfDiHY0SlP8fDwGHhq3ocwbP4TiuAevo= diff --git a/hugo.toml b/hugo.toml index 0eabeb9..c0310cc 100644 --- a/hugo.toml +++ b/hugo.toml @@ -2,15 +2,19 @@ title = "Señor Rolando" subtitle = "Lesender Läufer." baseURL = "https://sr-rolando.com" languageCode = "de-de" -theme = "ananke" +theme = ["github.com/theNewDynamic/gohugo-theme-ananke/v2"] resourceDir = "../resources" -DefaultContentLanguage = "de" -SectionPagesMenu = "no-default" # Prevent the automatic Hugo menu -Paginate = 10 -# googleAnalytics = "" +defaultContentLanguage = "de" +sectionPagesMenu = "no-default" # Prevent the automatic Hugo menu enableRobotsTXT = true +[services.googleAnalytics] +id = '' + +[pagination] +pagerSize = 10 + [sitemap] changefreq = "monthly" priority = 0.5 @@ -19,14 +23,17 @@ filename = "sitemap.xml" [params] text_color = "" author = "" -# favicon = "" site_logo = "" description = "Lesender Läufer." # Hero on start page. Choose a background color from any on this page: https://tachyons.io/docs/themes/skins/ and preface it with "bg-" background_color_class = "bg-dark-gray" +# choose fitting and alignment styles for the featured image using Tachyons classes such as "cover|contain" for fitting and "bg-top|bg-center|bg-bottom" for alignment, or add any other class space-separated to customize further +featured_image_class = "cover bg-top" +# choose a color dimming class for the page or site header from any on this page: https://tachyons.io/docs/themes/skins/, preface it with "bg-" and add the value such as "-X0" where X is in [1,9] +cover_dimming_class = "bg-black-60" recent_posts_number = 3 -mainSections = ["post","posts"] -logo = "img/avatar-icon.png" # Expecting square dimensions +# mainSections = ["post", "posts"] +logo = "img/avatar-icon.png" # Expecting square dimensions favicon = "/image/favicon.ico" dateFormat = "2. January 2006" commit = false @@ -38,16 +45,16 @@ comments = false readingTime = true wordCount = true useHLJS = true -socialShare = false # Don't add share buttons on posts -delayDisqus = true +socialShare = false # Don't add share buttons on posts +delayDisqus = false showRelatedPosts = true # hideAuthor = true [permalinks] - [permalinks.page] - post = '/:year/:month/:slug/' - [permalinks.section] - post = '/posts/' +[permalinks.page] +post = '/:year/:month/:slug/' +[permalinks.section] +post = '/posts/' [Author] # Set only your "username" for default hosts and full URLs otherwise (e.g., "https://MyGitLab.org/username") @@ -55,30 +62,36 @@ name = "Señor Rolando" website = "sr-rolando.com" # email = "web@sr-rolando.com" -[[params.ananke_socials]] -name = "mastodon" -url = "https://fnordon.de/@sr_rolando/" -rel = "me noopener" +[params.ananke.social.follow] +new_window_icon = true +# Options: ["bluesky", "mastodon", "rss"] +networks = ["mastodon", "rss"] -[[params.ananke_socials]] +[params.ananke.social.bluesky] +profilelink = "https://bsky.app/profile/sr-rolando.bsky.social" + +[params.ananke.social.mastodon] +profileLink = "https://fnordon.de/@sr_rolando/" + +[params.ananke.social.rss] name = "rss" url = "/index.xml" # No icon for Strava in Ananke for now # Doc for adding: https://github.com/theNewDynamic/gohugo-theme-ananke#social-icons-customization -# [[params.ananke_socials]] +# [params.ananke.social.strava] # name = "strava" # url = "https://www.strava.com/athletes/8075985" [[menu.main]] - name = "Texte" - url = "/book" - weight = 1 +name = "Texte" +url = "/book" +weight = 1 [[menu.main]] - name = "Läufe" - url = "/laeufer" - weight = 2 +name = "Läufe" +url = "/laeufer" +weight = 2 # Allow raw html div to be used. Mainly for posts imported from Wordpress. [markup.goldmark.renderer] diff --git a/layouts/partials/site-footer.html b/layouts/partials/site-footer.html index 3eb9183..183e3c0 100644 --- a/layouts/partials/site-footer.html +++ b/layouts/partials/site-footer.html @@ -5,6 +5,6 @@ Impressum Datenschutz -
{{ partial "social-follow.html" . }}
+
{{ partial "social/follow.html" . }}
diff --git a/themes/ananke b/themes/ananke deleted file mode 160000 index 33178c0..0000000 --- a/themes/ananke +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 33178c0d498edb18634bfe0f906ca191796ce307