From 970f121e119a6a0a09f870e941a3409fb5a83613 Mon Sep 17 00:00:00 2001 From: Bruno Carlin Date: Wed, 2 Jul 2025 23:58:44 +0200 Subject: [PATCH 1/3] fix(theme): correct styling for external links --- assets/static/css/bcarlin.css | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/assets/static/css/bcarlin.css b/assets/static/css/bcarlin.css index e1ee0e5..0c7db7c 100644 --- a/assets/static/css/bcarlin.css +++ b/assets/static/css/bcarlin.css @@ -92,16 +92,16 @@ header nav [role="link"]:is([aria-current]:not([aria-current="false"]),:hover,:a --pico-text-decoration: none; } -header :where(a:not([role="button"])) { - --pico-text-decoration: none; -} - .container { max-width: 40em; margin-left: auto; margin-right: auto; } +article :where(a:not([role="button"])) { + --pico-text-decoration: none; +} + /* * Layout Styling */ @@ -342,11 +342,13 @@ code, kbd, pre { } a[rel="external"]::after { - content: url('data:image/svg+xml,%3Csvg%20xmlns=%27http://www.w3.org/2000/svg%27%20viewBox=%270%200%2024%2024%27%20fill=%27currentColor%27%3E%3Cpath%20d=%27M10%206V8H5V19H16V14H18V20C18%2020.5523%2017.5523%2021%2017%2021H4C3.44772%2021%203%2020.5523%203%2020V7C3%206.44772%203.44772%206%204%206H10ZM21%203V11H19L18.9999%206.413L11.2071%2014.2071L9.79289%2012.7929L17.5849%205H13V3H21Z%27%3E%3C/path%3E%3C/svg%3E'); - width: 0.7em; - display: inline-block; + content: "\ecae"; + font-size: 0.7em; margin-left: 0.2em; - vertical-align: middle; + font-family: 'remixicon' !important; + font-style: normal; + color: var(--pico-muted-color); + text-decoration: none; } /* From 394d1556f756596080c57b18a7b2f9bf50f4f7f9 Mon Sep 17 00:00:00 2001 From: Bruno Carlin Date: Wed, 2 Jul 2025 23:58:44 +0200 Subject: [PATCH 2/3] feat(theme): wrap standalone images in figure tags --- assets/static/css/bcarlin.css | 6 +++++ config/_default/hugo.yaml | 3 +++ layouts/_markup/render-image.html | 45 +++++++++++++++++++++++++++++++ 3 files changed, 54 insertions(+) create mode 100644 layouts/_markup/render-image.html diff --git a/assets/static/css/bcarlin.css b/assets/static/css/bcarlin.css index 0c7db7c..99d2b22 100644 --- a/assets/static/css/bcarlin.css +++ b/assets/static/css/bcarlin.css @@ -351,6 +351,12 @@ a[rel="external"]::after { text-decoration: none; } +figure { + max-width: 50%; + text-align: center; + margin: var(--pico-block-spacing-vertical) auto; +} + /* * Admonitions */ diff --git a/config/_default/hugo.yaml b/config/_default/hugo.yaml index 9806098..cff0111 100644 --- a/config/_default/hugo.yaml +++ b/config/_default/hugo.yaml @@ -37,3 +37,6 @@ outputFormats: markup: highlight: noClasses: false + goldmark: + parser: + wrapStandAloneImageWithinParagraph: false diff --git a/layouts/_markup/render-image.html b/layouts/_markup/render-image.html new file mode 100644 index 0000000..f036ec4 --- /dev/null +++ b/layouts/_markup/render-image.html @@ -0,0 +1,45 @@ +{{- $u := urls.Parse .Destination -}} +{{- $path := strings.TrimPrefix "./" $u.Path -}} +{{- $res := or (.PageInner.Resources.Get $path) (resources.Get $path) -}} +{{- $src := $u.String -}} +{{- if not $u.IsAbs -}} + {{- with $res -}} + {{- $src = .RelPermalink -}} + {{- with $u.RawQuery -}} + {{- $src = printf "%s?%s" $src . -}} + {{- end -}} + {{- with $u.Fragment -}} + {{- $src = printf "%s#%s" $src . -}} + {{- end -}} + {{- end -}} +{{- end -}} + +{{- if .IsBlock -}} +
+ {{ .PlainText }} + {{- with $res.Params.legend -}} +
+ {{- . -}} +
+ {{- end -}} +
+{{- else -}} + {{ .PlainText }} +{{- end -}} + +{{- define "_partials/render-image.html" -}} +{{- end -}} From 8c7274db6364aa1afc39c8729e121a62379304c8 Mon Sep 17 00:00:00 2001 From: Bruno Carlin Date: Tue, 1 Jul 2025 00:09:11 +0200 Subject: [PATCH 3/3] DRAFTS --- content/blog/going-dark.en.md | 36 +++++++++++++++++++ .../hugo-translating-taxonomy-terms.en.md | 13 +++++++ content/blog/jj-main-vcs/index.en.md | 32 +++++++++++++++++ content/blog/jj-main-vcs/jj-logo.svg | 1 + 4 files changed, 82 insertions(+) create mode 100644 content/blog/going-dark.en.md create mode 100644 content/blog/hugo-translating-taxonomy-terms.en.md create mode 100644 content/blog/jj-main-vcs/index.en.md create mode 100644 content/blog/jj-main-vcs/jj-logo.svg diff --git a/content/blog/going-dark.en.md b/content/blog/going-dark.en.md new file mode 100644 index 0000000..fef3f25 --- /dev/null +++ b/content/blog/going-dark.en.md @@ -0,0 +1,36 @@ +--- +title: 'Going Dark' +slug: 'going-dark' +date: '2025-07-01T00:10:19+02:00' +draft: true +categories: +- Tooling +tags: +- darkman +- vivaldi +- waybar +- wofi +summary: | + entrer le résumé +description: | + entrer la description +--- + +I usually live in the terminal for most things: edit text files (neovim), +read and write emails (aerc), chat on Mattermost (matterhorn), browse files +(vifm), and so on. I might write on that later. My terminal and everything in it +is themed with Solarized Dark. That will not change. + +For the few GUI applications I use, the light theme is ery aggressive at night. +Here are some tips to automatically switch a few of them between light and dark +mode. + +## Automate with darkman + +## GTK Apps + +## Vivaldi + +## Add A Switcher To Waybar + +## Switch Wofi Theme diff --git a/content/blog/hugo-translating-taxonomy-terms.en.md b/content/blog/hugo-translating-taxonomy-terms.en.md new file mode 100644 index 0000000..40d3e73 --- /dev/null +++ b/content/blog/hugo-translating-taxonomy-terms.en.md @@ -0,0 +1,13 @@ +--- +title: 'Hugo Translating Taxonomy Terms' +slug: 'hugo-translating-taxonomy-terms' +date: '2025-07-02T22:35:43+02:00' +draft: true +categories: [] +tags: +- +summary: | + entrer le résumé +description: | + entrer la description +--- diff --git a/content/blog/jj-main-vcs/index.en.md b/content/blog/jj-main-vcs/index.en.md new file mode 100644 index 0000000..a71672c --- /dev/null +++ b/content/blog/jj-main-vcs/index.en.md @@ -0,0 +1,32 @@ +--- +title: 'I Use jj as my Main VCS' +slug: 'i-use-jj-as-my-main-vcs' +date: '2025-07-02T18:04:31+02:00' +draft: true +categories: +- Tooling +tags: +- jj +- git +summary: | + entrer le résumé +description: | + entrer la description +resources: +- src: jj-logo.svg + params: + legend: jj logo +--- + +I stumbled upon [jj] sometimes last year but I decided to give it a real go a +few month ago. It has already become my main VCS for all my code, even as a +replacement of git. + +![JJ Logo](jj-logo.svg) + +does things right: + +- jj git fetch removes local branches when the remote is removed +- undo that works + +[jj]: https://github.com/jj-vcs/jj diff --git a/content/blog/jj-main-vcs/jj-logo.svg b/content/blog/jj-main-vcs/jj-logo.svg new file mode 100644 index 0000000..3b77bb6 --- /dev/null +++ b/content/blog/jj-main-vcs/jj-logo.svg @@ -0,0 +1 @@ +