summaryrefslogtreecommitdiff
path: root/gemfeed
diff options
context:
space:
mode:
Diffstat (limited to 'gemfeed')
-rw-r--r--gemfeed/2008-06-26-perl-poetry.html1
-rw-r--r--gemfeed/2011-05-07-perl-daemon-service-framework.html1
-rw-r--r--gemfeed/2022-05-27-perl-is-still-a-great-choice.html1
-rw-r--r--gemfeed/2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html1
-rw-r--r--gemfeed/2025-06-22-task-samurai.html1
-rw-r--r--gemfeed/2025-08-05-local-coding-llm-with-ollama.html1
-rw-r--r--gemfeed/2025-11-02-perl-new-features-and-foostats.html1
-rw-r--r--gemfeed/2026-02-14-meta-slash-commands-for-prompts-and-context.html3
-rw-r--r--gemfeed/2026-02-14-til-meta-slash-commands-for-ai-workflows.html110
-rw-r--r--gemfeed/2026-02-15-loadbars-resurrected-from-perl-to-go.html253
-rw-r--r--gemfeed/atom.xml786
-rw-r--r--gemfeed/index.html2
-rw-r--r--gemfeed/loadbars-resurrected-from-perl-to-go/loadbars.gifbin0 -> 93467 bytes
13 files changed, 729 insertions, 432 deletions
diff --git a/gemfeed/2008-06-26-perl-poetry.html b/gemfeed/2008-06-26-perl-poetry.html
index d54b7210..dcbd8ae7 100644
--- a/gemfeed/2008-06-26-perl-poetry.html
+++ b/gemfeed/2008-06-26-perl-poetry.html
@@ -196,6 +196,7 @@ This is perl, v5.<font color="#000000">8.8</font> built <b><u><font color="#0000
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 Loadbars resurrected: From Perl to Go after 15 years</a><br />
<a class='textlink' href='./2025-11-02-perl-new-features-and-foostats.html'>2025-11-02 Perl New Features and Foostats</a><br />
<a class='textlink' href='./2022-05-27-perl-is-still-a-great-choice.html'>2022-05-27 Perl is still a great choice</a><br />
<a class='textlink' href='./2011-05-07-perl-daemon-service-framework.html'>2011-05-07 Perl Daemon (Service Framework)</a><br />
diff --git a/gemfeed/2011-05-07-perl-daemon-service-framework.html b/gemfeed/2011-05-07-perl-daemon-service-framework.html
index d68f12ca..93111dc5 100644
--- a/gemfeed/2011-05-07-perl-daemon-service-framework.html
+++ b/gemfeed/2011-05-07-perl-daemon-service-framework.html
@@ -208,6 +208,7 @@ http://www.gnu.org/software/src-highlite -->
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 Loadbars resurrected: From Perl to Go after 15 years</a><br />
<a class='textlink' href='./2025-11-02-perl-new-features-and-foostats.html'>2025-11-02 Perl New Features and Foostats</a><br />
<a class='textlink' href='./2022-05-27-perl-is-still-a-great-choice.html'>2022-05-27 Perl is still a great choice</a><br />
<a class='textlink' href='./2011-05-07-perl-daemon-service-framework.html'>2011-05-07 Perl Daemon (Service Framework) (You are currently reading this)</a><br />
diff --git a/gemfeed/2022-05-27-perl-is-still-a-great-choice.html b/gemfeed/2022-05-27-perl-is-still-a-great-choice.html
index cd17d661..225299f3 100644
--- a/gemfeed/2022-05-27-perl-is-still-a-great-choice.html
+++ b/gemfeed/2022-05-27-perl-is-still-a-great-choice.html
@@ -166,6 +166,7 @@
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 Loadbars resurrected: From Perl to Go after 15 years</a><br />
<a class='textlink' href='./2025-11-02-perl-new-features-and-foostats.html'>2025-11-02 Perl New Features and Foostats</a><br />
<a class='textlink' href='./2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html'>2023-05-01 Unveiling <span class='inlinecode'>guprecords.raku</span>: Global Uptime Records with Raku</a><br />
<a class='textlink' href='./2022-05-27-perl-is-still-a-great-choice.html'>2022-05-27 Perl is still a great choice (You are currently reading this)</a><br />
diff --git a/gemfeed/2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html b/gemfeed/2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html
index 6b832a86..45bb0cbc 100644
--- a/gemfeed/2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html
+++ b/gemfeed/2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html
@@ -180,6 +180,7 @@ no1 in 455 days, 18:52:44 | at Sun Jul 21 07:37:51 2024
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 Loadbars resurrected: From Perl to Go after 15 years</a><br />
<a class='textlink' href='./2025-11-02-perl-new-features-and-foostats.html'>2025-11-02 Perl New Features and Foostats</a><br />
<a class='textlink' href='./2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html'>2023-05-01 Unveiling <span class='inlinecode'>guprecords.raku</span>: Global Uptime Records with Raku (You are currently reading this)</a><br />
<a class='textlink' href='./2022-06-15-sweating-the-small-stuff.html'>2022-06-15 Sweating the small stuff - Tiny projects of mine</a><br />
diff --git a/gemfeed/2025-06-22-task-samurai.html b/gemfeed/2025-06-22-task-samurai.html
index 9e10795d..48246de3 100644
--- a/gemfeed/2025-06-22-task-samurai.html
+++ b/gemfeed/2025-06-22-task-samurai.html
@@ -145,6 +145,7 @@
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-14-til-meta-slash-commands-for-ai-workflows.html'>2026-02-14 TIL: Meta slash-commands for reusable AI prompts and context</a><br />
<a class='textlink' href='./2025-08-05-local-coding-llm-with-ollama.html'>2025-08-05 Local LLM for Coding with Ollama on macOS</a><br />
<a class='textlink' href='./2025-06-22-task-samurai.html'>2025-06-22 Task Samurai: An agentic coding learning experiment (You are currently reading this)</a><br />
<br />
diff --git a/gemfeed/2025-08-05-local-coding-llm-with-ollama.html b/gemfeed/2025-08-05-local-coding-llm-with-ollama.html
index f2a9d99d..076ce21e 100644
--- a/gemfeed/2025-08-05-local-coding-llm-with-ollama.html
+++ b/gemfeed/2025-08-05-local-coding-llm-with-ollama.html
@@ -466,6 +466,7 @@ content = "{CODE}"
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-14-til-meta-slash-commands-for-ai-workflows.html'>2026-02-14 TIL: Meta slash-commands for reusable AI prompts and context</a><br />
<a class='textlink' href='./2025-08-05-local-coding-llm-with-ollama.html'>2025-08-05 Local LLM for Coding with Ollama on macOS (You are currently reading this)</a><br />
<a class='textlink' href='./2025-06-22-task-samurai.html'>2025-06-22 Task Samurai: An agentic coding learning experiment</a><br />
<br />
diff --git a/gemfeed/2025-11-02-perl-new-features-and-foostats.html b/gemfeed/2025-11-02-perl-new-features-and-foostats.html
index 7e3ab9c9..85c36f60 100644
--- a/gemfeed/2025-11-02-perl-new-features-and-foostats.html
+++ b/gemfeed/2025-11-02-perl-new-features-and-foostats.html
@@ -449,6 +449,7 @@ http://www.gnu.org/software/src-highlite -->
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 Loadbars resurrected: From Perl to Go after 15 years</a><br />
<a class='textlink' href='./2025-11-02-perl-new-features-and-foostats.html'>2025-11-02 Perl New Features and Foostats (You are currently reading this)</a><br />
<a class='textlink' href='./2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html'>2023-05-01 Unveiling <span class='inlinecode'>guprecords.raku</span>: Global Uptime Records with Raku</a><br />
<a class='textlink' href='./2022-05-27-perl-is-still-a-great-choice.html'>2022-05-27 Perl is still a great choice</a><br />
diff --git a/gemfeed/2026-02-14-meta-slash-commands-for-prompts-and-context.html b/gemfeed/2026-02-14-meta-slash-commands-for-prompts-and-context.html
index 3e086905..38934e1b 100644
--- a/gemfeed/2026-02-14-meta-slash-commands-for-prompts-and-context.html
+++ b/gemfeed/2026-02-14-meta-slash-commands-for-prompts-and-context.html
@@ -235,7 +235,8 @@
<br />
<span>Other related posts:</span><br />
<br />
-<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>2026-02-14 Meta slash-commands to manage prompts and context (You are currently reading this)</a><br />
+<a class='textlink' href='./2026-02-14-til-meta-slash-commands-for-ai-workflows.html'>2026-02-14 TIL: Meta slash-commands for reusable AI prompts and context</a><br />
+<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>2026-02-14 Meta slash-commands to manage prompts and context for coding agents (You are currently reading this)</a><br />
<a class='textlink' href='./2026-02-02-tmux-popup-editor-for-cursor-agent-prompts.html'>2026-02-02 A tmux popup editor for Cursor Agent CLI prompts</a><br />
<br />
<span>E-Mail your comments to <span class='inlinecode'>paul@nospam.buetow.org</span> :-)</span><br />
diff --git a/gemfeed/2026-02-14-til-meta-slash-commands-for-ai-workflows.html b/gemfeed/2026-02-14-til-meta-slash-commands-for-ai-workflows.html
new file mode 100644
index 00000000..246d1d3f
--- /dev/null
+++ b/gemfeed/2026-02-14-til-meta-slash-commands-for-ai-workflows.html
@@ -0,0 +1,110 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+<title>TIL: Meta slash-commands for reusable AI prompts and context</title>
+<link rel="shortcut icon" type="image/gif" href="/favicon.ico" />
+<link rel="stylesheet" href="../style.css" />
+<link rel="stylesheet" href="style-override.css" />
+</head>
+<body>
+<p class="header">
+<a href="https://foo.zone">Home</a> | <a href="https://codeberg.org/snonux/foo.zone/src/branch/content-md/gemfeed/2026-02-14-til-meta-slash-commands-for-ai-workflows.md">Markdown</a> | <a href="gemini://foo.zone/gemfeed/2026-02-14-til-meta-slash-commands-for-ai-workflows.gmi">Gemini</a>
+</p>
+<h1 style='display: inline' id='til-meta-slash-commands-for-reusable-ai-prompts-and-context'>TIL: Meta slash-commands for reusable AI prompts and context</h1><br />
+<br />
+<span class='quote'>Published at 2026-02-14T14:00:00+02:00</span><br />
+<br />
+<span>Short post in "This week I learned" style: what I tried, why it worked, and how you can replicate it. Format: Problem → Approach → Copy/paste → Result → Gotchas. Full reference for the meta-commands lives in a separate post.</span><br />
+<br />
+<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>Full reference: Meta slash-commands to manage prompts and context for coding agents</a><br />
+<br />
+<h2 style='display: inline' id='til'>TIL</h2><br />
+<br />
+<h3 style='display: inline' id='problem'>Problem</h3><br />
+<br />
+<span>When I use a coding agent (Cursor Agent, Claude Code CLI, Ampcode, etc.), I repeat the same requests: "review this function," "explain this error," "add tests for this module," "format this as a blog post." Typing long prompts from scratch is tedious; ad-hoc prompts are easy to forget. I also keep pasting the same background (API conventions, project rules, infra notes) into every session so the agent doesn&#39;t guess blindly.</span><br />
+<br />
+<h3 style='display: inline' id='approach'>Approach</h3><br />
+<br />
+<span>Treat prompts and context as first-class artefacts: store them as markdown files (one per slash-command or per context) in a dotfiles repo. Use a small set of *meta* slash-commands so the agent itself creates, updates, and deletes these files from the conversation—no hand-editing. Two kinds of artefacts:</span><br />
+<br />
+<ul>
+<li>Commands — Reusable workflows (e.g. review-code, explain-error). Live in <span class='inlinecode'>commands/</span> as <span class='inlinecode'>.md</span> files.</li>
+<li>Context — Reusable background (API guidelines, runbooks, personas). Live in <span class='inlinecode'>context/</span> as <span class='inlinecode'>.md</span> files; you *load* one at session start so the agent has it in mind.</li>
+</ul><br />
+<h3 style='display: inline' id='copypaste'>Copy/paste</h3><br />
+<br />
+<span>Minimal workflow:</span><br />
+<br />
+<pre>
+/load-context api-guidelines
+</pre>
+<br />
+<span>Then ask the agent to implement a feature or fix a bug; it already has the guidelines.</span><br />
+<br />
+<span>To turn something you just did into a reusable command:</span><br />
+<br />
+<pre>
+/create-command review-code
+</pre>
+<br />
+<span>Full command reference (all meta-commands, parameters, examples):</span><br />
+<br />
+<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>Meta slash-commands — full reference</a><br />
+<br />
+<h3 style='display: inline' id='result'>Result</h3><br />
+<br />
+<span>No more retyping long prompts; same prompt library across Cursor Agent, Claude Code CLI, OpenCode, Ampcode. Context is load-on-demand per session instead of pasting walls of text. Everything is versioned in git and synced across machines.</span><br />
+<br />
+<h3 style='display: inline' id='gotchas'>Gotchas</h3><br />
+<br />
+<ul>
+<li>Requires an agent that supports custom slash-commands (or reading prompt files from disk).</li>
+<li>Context is explicit: you must run <span class='inlinecode'>/load-context &lt;name&gt;</span> at session start; it&#39;s not implicit like some "skills" systems.</li>
+<li>A flat directory of commands can grow; if it gets unwieldy, consider grouping by skill or exposing via an MCP server later.</li>
+</ul><br />
+<h2 style='display: inline' id='beforeafter'>Before/After</h2><br />
+<br />
+<ul>
+<li>Before: Retyping or pasting long prompts each time; pasting API/project context into every session; prompts scattered and inconsistent across tools.</li>
+<li>After: <span class='inlinecode'>/load-context &lt;name&gt;</span> once per session; <span class='inlinecode'>/&lt;command&gt;</span> for repeatable tasks; commands and context in git, same library across agents.</li>
+</ul><br />
+<h2 style='display: inline' id='workflow-recipe'>Workflow recipe</h2><br />
+<br />
+<ul>
+<li>Steps: (1) Create or update context/commands via meta-commands when you have something worth reusing. (2) Start a session → run <span class='inlinecode'>/load-context &lt;name&gt;</span>. (3) Use slash-commands or ask ad-hoc; agent has background and consistent prompts.</li>
+<li>Tools: Cursor Agent (CLI), Claude Code CLI, OpenCode, Ampcode; markdown in e.g. <span class='inlinecode'>~/Notes/Prompts/commands/</span> and <span class='inlinecode'>~/Notes/Prompts/context/</span>.</li>
+<li>Impact: Saves retyping and keeps prompts consistent; one-time cost is creating the first context/command with the agent.</li>
+</ul><br />
+<h2 style='display: inline' id='micro-template-quick-reference'>Micro-template (quick reference)</h2><br />
+<br />
+<span>| Meta-command | Purpose | Good for |</span><br />
+<span>|--------------------|--------------------------------|-------------------------------------------|</span><br />
+<span>| /create-command | Create new slash-command | Turn current or recurring tasks into one |</span><br />
+<span>| /update-command | Edit existing slash-command | Refine after use |</span><br />
+<span>| /delete-command | Remove slash-command file | Clean up unused commands |</span><br />
+<span>| /create-context | Create new context file | Capture project/infra knowledge once |</span><br />
+<span>| /update-context | Edit existing context file | Keep context up to date |</span><br />
+<span>| /delete-context | Remove context file | Remove outdated context |</span><br />
+<span>| /load-context | Load context into conversation | Give agent background before tasks |</span><br />
+<br />
+<span>Example usage: <span class='inlinecode'>/load-context api-guidelines</span>, <span class='inlinecode'>/create-command review-code</span>, <span class='inlinecode'>/update-command review-code</span>. Full details and examples in the main post linked above.</span><br />
+<br />
+<span>Other related posts:</span><br />
+<br />
+<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>2026-02-14 Meta slash-commands to manage prompts and context for coding agents</a><br />
+<a class='textlink' href='./2026-02-02-tmux-popup-editor-for-cursor-agent-prompts.html'>2026-02-02 A tmux popup editor for Cursor Agent CLI prompts</a><br />
+<br />
+<span>E-Mail your comments to <span class='inlinecode'>paul@nospam.buetow.org</span> :-)</span><br />
+<br />
+<a class='textlink' href='../'>Back to the main site</a><br />
+<p class="footer">
+ Generated with <a href="https://codeberg.org/snonux/gemtexter">Gemtexter 3.0.1-develop</a> |
+ served by <a href="https://www.OpenBSD.org">OpenBSD</a>/<a href="https://man.openbsd.org/relayd.8">relayd(8)</a>+<a href="https://man.openbsd.org/httpd.8">httpd(8)</a> |
+ <a href="https://foo.zone/site-mirrors.html">Site Mirrors</a>
+ <br />
+ Webring: <a href="https://shring.sh/foo.zone/previous">previous</a> | <a href="https://shring.sh">shring</a> | <a href="https://shring.sh/foo.zone/next">next</a>
+</p>
+</body>
+</html>
diff --git a/gemfeed/2026-02-15-loadbars-resurrected-from-perl-to-go.html b/gemfeed/2026-02-15-loadbars-resurrected-from-perl-to-go.html
new file mode 100644
index 00000000..0c530143
--- /dev/null
+++ b/gemfeed/2026-02-15-loadbars-resurrected-from-perl-to-go.html
@@ -0,0 +1,253 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
+<head>
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+<title>Loadbars resurrected: From Perl to Go after 15 years</title>
+<link rel="shortcut icon" type="image/gif" href="/favicon.ico" />
+<link rel="stylesheet" href="../style.css" />
+<link rel="stylesheet" href="style-override.css" />
+</head>
+<body>
+<p class="header">
+<a href="https://foo.zone">Home</a> | <a href="https://codeberg.org/snonux/foo.zone/src/branch/content-md/gemfeed/2026-02-15-loadbars-resurrected-from-perl-to-go.md">Markdown</a> | <a href="gemini://foo.zone/gemfeed/2026-02-15-loadbars-resurrected-from-perl-to-go.gmi">Gemini</a>
+</p>
+<h1 style='display: inline' id='loadbars-resurrected-from-perl-to-go-after-15-years'>Loadbars resurrected: From Perl to Go after 15 years</h1><br />
+<br />
+<span class='quote'>Published at 2026-02-14T22:43:27+02:00</span><br />
+<br />
+<span>Who remembers Loadbars? The small, humble server load monitoring tool I wrote back in November 2010 as a Perl+SDL project during my first job after graduating from university as a Linux Sysadmin. That was over 15 years ago. After being effectively dead for more than a decade, Loadbars is working again -- rewritten in Go from Perl with the help of AI (Claude Code), and it even works on macOS now (as a client).</span><br />
+<br />
+<a href='./loadbars-resurrected-from-perl-to-go/loadbars.gif'><img alt='Loadbars in action' title='Loadbars in action' src='./loadbars-resurrected-from-perl-to-go/loadbars.gif' /></a><br />
+<br />
+<a class='textlink' href='https://codeberg.org/snonux/loadbars'>Loadbars on Codeberg</a><br />
+<br />
+<h2 style='display: inline' id='table-of-contents'>Table of Contents</h2><br />
+<br />
+<ul>
+<li><a href='#loadbars-resurrected-from-perl-to-go-after-15-years'>Loadbars resurrected: From Perl to Go after 15 years</a></li>
+<li>⇢ <a href='#what-loadbars-is-and-isn-t'>What Loadbars is (and isn&#39;t)</a></li>
+<li>⇢ <a href='#why-the-rewrite-was-necessary'>Why the rewrite was necessary</a></li>
+<li>⇢ <a href='#a-brief-history'>A brief history</a></li>
+<li>⇢ <a href='#features'>Features</a></li>
+<li>⇢ ⇢ <a href='#cpu-monitoring'>CPU monitoring</a></li>
+<li>⇢ ⇢ <a href='#memory-monitoring'>Memory monitoring</a></li>
+<li>⇢ ⇢ <a href='#network-monitoring'>Network monitoring</a></li>
+<li>⇢ ⇢ <a href='#all-hotkeys'>All hotkeys</a></li>
+<li>⇢ ⇢ <a href='#ssh-and-multi-host-support'>SSH and multi-host support</a></li>
+<li>⇢ ⇢ <a href='#config-file'>Config file</a></li>
+<li>⇢ ⇢ <a href='#macos-support'>macOS support</a></li>
+<li>⇢ <a href='#building-from-source'>Building from source</a></li>
+<li>⇢ <a href='#tested-platforms'>Tested platforms</a></li>
+<li>⇢ <a href='#future-proof-with-go'>Future-proof with Go</a></li>
+<li>⇢ <a href='#the-ai-rewrite-experience'>The AI rewrite experience</a></li>
+</ul><br />
+<h2 style='display: inline' id='what-loadbars-is-and-isn-t'>What Loadbars is (and isn&#39;t)</h2><br />
+<br />
+<span>Loadbars is a real-time server load monitoring tool. It connects to one or more Linux hosts via SSH and shows CPU, memory, and network usage as vertical colored bars in an SDL window. You can also run it locally without SSH. It shows the current state only -- like <span class='inlinecode'>top</span> or <span class='inlinecode'>vmstat</span>, but visual and across multiple hosts at once. All you need is a working SSH connection through an SSH Agent.</span><br />
+<br />
+<span>It is not a tool for collecting loads and drawing graphs for later analysis. There is no history, no recording, no database. Tools like Prometheus or Grafana require significant setup time before producing results. Loadbars lets you observe the current state immediately. You install one binary, point it at your servers, and see what&#39;s happening right now.</span><br />
+<br />
+<pre>
+┌─ Loadbars 0.9.0 ──────────────────────────────────────────┐
+│ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ▓▓▓▓ ▓▓▓▓ ▓▓▓▓ ▓▓ ▓▓▓▓ ▓▓▓▓ ▓▓▓▓ ▓▓ ░░▓▓ ░░▓▓ │
+│ CPU cpu0 cpu1 mem CPU cpu0 cpu1 mem net net │
+│ └──── host1 ────┘ └──── host2 ────┘ │
+└───────────────────────────────────────────────────────────┘
+</pre>
+<br />
+<h2 style='display: inline' id='why-the-rewrite-was-necessary'>Why the rewrite was necessary</h2><br />
+<br />
+<span>I&#39;d have liked to have kept the Perl version. Perl was the first language I learned properly, and I have a soft spot for it. But there was an (for me) unresolvable multithreading issue related to recent Perl and SDL library versions. Perl&#39;s <span class='inlinecode'>ithreads</span> and SDL doesn&#39;t work reliably anymore, and debugging decade-old thread-safety issues in XS bindings is not a productive use of time.</span><br />
+<br />
+<span>I actually tried to fix the Perl version first. I had Claude Code (CLI, running Opus 5.3) attempt to resolve the segfault involving Perl&#39;s multi-threading and SDL. It couldn&#39;t—the issue is deep in the XS bindings and not something you can fix from Perl-land (nor did I want to invest my own time in it either). So the more pragmatic thing to do was to let Claude Code rewrite the whole thing in Go instead. That worked without any major issues. The Go version is cleaner, faster to build, easier to deploy (single static binary), and now has proper unit tests.</span><br />
+<br />
+<span>The important thing: for the user, nothing changes. The rewrite&#39;s usage, look, and feel are de-facto identical to the old Perl version. The same hotkeys, the same bar layout, the same colors, the same config file format. If you used Loadbars ten years ago, you can pick up the new version and everything works exactly as you remember. The only difference is under the hood.</span><br />
+<br />
+<h2 style='display: inline' id='a-brief-history'>A brief history</h2><br />
+<br />
+<span>The first commit is from November 5, 2010—over 13 years ago. Back then, it was called <span class='inlinecode'>cpuload</span> and was a quick Perl+SDL hack I wrote at work to keep an eye on a fleet of Linux servers. It grew into Loadbars over the following weeks, gaining memory and network monitoring, ClusterSSH integration, and a config file. The last meaningful Perl development was around 2013. Around that time, there were already a couple of colleagues who used Loadbars frequently. But then I changed my job role and later even jobs, and I stopped development of Loadbars.</span><br />
+<br />
+<span>For the next decade, it sat dormant. I occasionally thought about reviving it, but Perl+SDL threading issues made it impractical. In February 2026, I finally sat down with Claude Code and let it rewrite the whole thing in Go in a single session.</span><br />
+<br />
+<h2 style='display: inline' id='features'>Features</h2><br />
+<br />
+<h3 style='display: inline' id='cpu-monitoring'>CPU monitoring</h3><br />
+<br />
+<span>CPU usage is shown as vertical colored bars. Each bar is stacked from bottom to top with the following segments:</span><br />
+<br />
+<ul>
+<li>System (blue) -- kernel CPU time</li>
+<li>User (yellow) -- user-space CPU time; turns dark yellow above 50%, orange above 70%</li>
+<li>Nice (green) -- low-priority user processes</li>
+<li>Idle (black) -- unused CPU</li>
+<li>IOwait (purple) -- waiting for disk I/O</li>
+<li>IRQ / SoftIRQ (white) -- interrupt handling</li>
+<li>Guest (red) -- time spent running virtual CPUs</li>
+<li>Steal (red) -- time stolen by the hypervisor</li>
+</ul><br />
+<span>Press <span class='inlinecode'>1</span> to toggle between one aggregate bar per host and one bar per core. Press <span class='inlinecode'>e</span> for extended mode, which adds a 1px peak line showing the maximum system+user percentage over the last N samples.</span><br />
+<br />
+<h3 style='display: inline' id='memory-monitoring'>Memory monitoring</h3><br />
+<br />
+<span>Press <span class='inlinecode'>2</span> to toggle memory bars. Each host gets one bar split in two halves:</span><br />
+<br />
+<ul>
+<li>Left half: RAM usage (dark grey = used, black = free)</li>
+<li>Right half: Swap usage (grey = used, black = free)</li>
+</ul><br />
+<h3 style='display: inline' id='network-monitoring'>Network monitoring</h3><br />
+<br />
+<span>Press <span class='inlinecode'>3</span> to toggle network bars. Loadbars sums RX and TX bytes across all non-loopback interfaces (e.g. <span class='inlinecode'>eth0</span>, <span class='inlinecode'>wlan0</span>, <span class='inlinecode'>enp0s3</span>) and shows the combined total. Loopback (<span class='inlinecode'>lo</span>) is always excluded. Each net bar has two halves:</span><br />
+<br />
+<ul>
+<li>Left half: RX (received) growing from the top (light green)</li>
+<li>Right half: TX (transmitted) growing from the bottom (light green)</li>
+</ul><br />
+<span>Network utilization is shown as a percentage of the configured link speed. The default link speed is <span class='inlinecode'>gbit</span> (1 Gbps). Change it with <span class='inlinecode'>--netlink</span> or in the config file. Press <span class='inlinecode'>f</span>/<span class='inlinecode'>v</span> to scale the link speed up or down during runtime (cycles through mbit, 10mbit, 100mbit, gbit, 10gbit).</span><br />
+<br />
+<span>If the net bar is red, it means no non-loopback interface was found on that host.</span><br />
+<br />
+<h3 style='display: inline' id='all-hotkeys'>All hotkeys</h3><br />
+<br />
+<pre>
+Key Action
+───── ──────────────────────────────────────────────────
+1 Toggle CPU cores (aggregate vs per-core bars)
+2 Toggle memory bars
+3 Toggle network bars (aggregated across interfaces)
+e Toggle extended display (peak line on CPU bars)
+h Print hotkey list to stdout
+q Quit
+w Write current settings to ~/.loadbarsrc
+a / y Increase / decrease CPU average samples
+d / c Increase / decrease net average samples
+f / v Link scale up / down (net utilization reference)
+Arrows Resize window (left/right: width, up/down: height)
+</pre>
+<br />
+<h3 style='display: inline' id='ssh-and-multi-host-support'>SSH and multi-host support</h3><br />
+<br />
+<span>Loadbars connects to remote hosts via SSH using public key authentication. No agent or special setup is needed on the remote side -- Loadbars embeds a small bash script in the binary and runs it via <span class='inlinecode'>bash -s</span> over SSH. The remote hosts only need bash and <span class='inlinecode'>/proc</span> (i.e. Linux).</span><br />
+<br />
+<pre>
+loadbars --hosts server1,server2,server3
+
+loadbars --hosts root@server1,root@server2
+
+loadbars servername{01..50}.example.com --showcores 1
+</pre>
+<br />
+<span>Shell brace expansion works for specifying ranges of hosts. You can also use ClusterSSH cluster definitions from <span class='inlinecode'>/etc/clusters</span>:</span><br />
+<br />
+<pre>
+loadbars --cluster production
+</pre>
+<br />
+<span>When no hosts are given, Loadbars runs locally on <span class='inlinecode'>localhost</span> without SSH.</span><br />
+<br />
+<h3 style='display: inline' id='config-file'>Config file</h3><br />
+<br />
+<span>Loadbars reads <span class='inlinecode'>~/.loadbarsrc</span> on startup. Any option from <span class='inlinecode'>--help</span> can be set there without the leading <span class='inlinecode'>--</span>. Comments use <span class='inlinecode'>#</span>. Press <span class='inlinecode'>w</span> during runtime to write the current settings to the config file.</span><br />
+<br />
+<pre>
+showcores=1
+showmem=1
+shownet=1
+extended=1
+netlink=gbit
+cpuaverage=10
+netaverage=15
+height=150
+barwidth=1200
+</pre>
+<br />
+<h3 style='display: inline' id='macos-support'>macOS support</h3><br />
+<br />
+<span>macOS is supported as a client for monitoring remote Linux servers via SSH. Local monitoring on macOS is not supported because it requires the <span class='inlinecode'>/proc</span> filesystem. The SDL window is automatically brought to the foreground on macOS.</span><br />
+<br />
+<h2 style='display: inline' id='building-from-source'>Building from source</h2><br />
+<br />
+<span>Loadbars requires Go 1.25+ and SDL2. Install the SDL2 development libraries for your platform:</span><br />
+<br />
+<pre>
+# Fedora / RHEL / CentOS
+sudo dnf install SDL2-devel
+
+# macOS
+brew install sdl2
+</pre>
+<br />
+<span>Then build with Mage (recommended) or plain Go:</span><br />
+<br />
+<pre>
+mage build
+./loadbars --hosts localhost
+
+# or without Mage:
+go build -o loadbars ./cmd/loadbars
+</pre>
+<br />
+<span>Install to <span class='inlinecode'>~/go/bin</span>:</span><br />
+<br />
+<pre>
+mage install
+</pre>
+<br />
+<span>Run tests:</span><br />
+<br />
+<pre>
+mage test
+# or: go test ./...
+</pre>
+<br />
+<h2 style='display: inline' id='tested-platforms'>Tested platforms</h2><br />
+<br />
+<ul>
+<li>Fedora Linux 43 and most modern Linux distributions (RHEL, CentOS, Ubuntu, Debian, etc.)</li>
+<li>macOS (Darwin) as a client connecting to remote Linux servers via SSH</li>
+</ul><br />
+<span>Remote hosts must be Linux with <span class='inlinecode'>/proc</span> and bash.</span><br />
+<br />
+<h2 style='display: inline' id='future-proof-with-go'>Future-proof with Go</h2><br />
+<br />
+<span>One of the reasons I chose Go for the rewrite is Go&#39;s compatibility promise. The Go 1 compatibility guarantee means that code written today will continue to compile and work with future Go releases. No more bitrotted XS bindings, no more <span class='inlinecode'>ithreads</span> headaches, no more hunting for compatible versions of SDL Perl modules.</span><br />
+<br />
+<span>The Go SDL2 bindings (go-sdl2) are actively maintained, and SDL2 itself is a stable, well-supported library. The entire application compiles to a single static binary with no runtime dependencies beyond SDL2. Deploy it anywhere, run it for years.</span><br />
+<br />
+<h2 style='display: inline' id='the-ai-rewrite-experience'>The AI rewrite experience</h2><br />
+<br />
+<span>This resurrection would not have been really possible without the help of AI. The rewrite was done with Claude Code CLI (Anthropic&#39;s coding agent) running Claude Opus 5.3. I pointed it at the Perl source, and let it produce the Go equivalent. The process was surprisingly smooth -- the rewrite worked without any major issues. There were some minor bugs (such as network bars not showing up initially, and/or some pixel errors in the bars), but they were sorted by Claude by providing screenshots of the problems.</span><br />
+<br />
+<span>E-Mail your comments to <span class='inlinecode'>paul@nospam.buetow.org</span> :-)</span><br />
+<br />
+<span>Other related posts:</span><br />
+<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 Loadbars resurrected: From Perl to Go after 15 years (You are currently reading this)</a><br />
+<a class='textlink' href='./2025-11-02-perl-new-features-and-foostats.html'>2025-11-02 Perl New Features and Foostats</a><br />
+<a class='textlink' href='./2025-09-14-bash-golf-part-4.html'>2025-09-14 Bash Golf Part 4</a><br />
+<a class='textlink' href='./2025-03-05-sharing-on-social-media-with-gos.html'>2025-03-05 Sharing on Social Media with Gos v1.0.0</a><br />
+<a class='textlink' href='./2024-03-03-a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang.html'>2024-03-03 A fine Fyne Android app for quickly logging ideas programmed in Go</a><br />
+<a class='textlink' href='./2023-12-10-bash-golf-part-3.html'>2023-12-10 Bash Golf Part 3</a><br />
+<a class='textlink' href='./2023-06-01-kiss-server-monitoring-with-gogios.html'>2023-06-01 KISS server monitoring with Gogios</a><br />
+<a class='textlink' href='./2022-05-27-perl-is-still-a-great-choice.html'>2022-05-27 Perl is still a great choice</a><br />
+<a class='textlink' href='./2022-01-01-bash-golf-part-2.html'>2022-01-01 Bash Golf Part 2</a><br />
+<a class='textlink' href='./2021-11-29-bash-golf-part-1.html'>2021-11-29 Bash Golf Part 1</a><br />
+<a class='textlink' href='./2011-05-07-perl-daemon-service-framework.html'>2011-05-07 Perl Daemon (Service Framework)</a><br />
+<a class='textlink' href='./2008-06-26-perl-poetry.html'>2008-06-26 Perl Poetry</a><br />
+<br />
+<a class='textlink' href='../'>Back to the main site</a><br />
+<p class="footer">
+ Generated with <a href="https://codeberg.org/snonux/gemtexter">Gemtexter 3.0.1-develop</a> |
+ served by <a href="https://www.OpenBSD.org">OpenBSD</a>/<a href="https://man.openbsd.org/relayd.8">relayd(8)</a>+<a href="https://man.openbsd.org/httpd.8">httpd(8)</a> |
+ <a href="https://foo.zone/site-mirrors.html">Site Mirrors</a>
+ <br />
+ Webring: <a href="https://shring.sh/foo.zone/previous">previous</a> | <a href="https://shring.sh">shring</a> | <a href="https://shring.sh/foo.zone/next">next</a>
+</p>
+</body>
+</html>
diff --git a/gemfeed/atom.xml b/gemfeed/atom.xml
index 78173b79..ff77d61a 100644
--- a/gemfeed/atom.xml
+++ b/gemfeed/atom.xml
@@ -1,12 +1,359 @@
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
- <updated>2026-02-14T13:44:46+02:00</updated>
+ <updated>2026-02-14T22:43:28+02:00</updated>
<title>foo.zone feed</title>
<subtitle>To be in the .zone!</subtitle>
<link href="https://foo.zone/gemfeed/atom.xml" rel="self" />
<link href="https://foo.zone/" />
<id>https://foo.zone/</id>
<entry>
+ <title>Loadbars resurrected: From Perl to Go after 15 years</title>
+ <link href="https://foo.zone/gemfeed/2026-02-15-loadbars-resurrected-from-perl-to-go.html" />
+ <id>https://foo.zone/gemfeed/2026-02-15-loadbars-resurrected-from-perl-to-go.html</id>
+ <updated>2026-02-14T22:43:27+02:00</updated>
+ <author>
+ <name>Paul Buetow aka snonux</name>
+ <email>paul@dev.buetow.org</email>
+ </author>
+ <summary>Who remembers Loadbars? The small, humble server load monitoring tool I wrote back in November 2010 as a Perl+SDL project during my first job after graduating from university as a Linux Sysadmin. That was over 15 years ago. After being effectively dead for more than a decade, Loadbars is working again -- rewritten in Go from Perl with the help of AI (Claude Code), and it even works on macOS now (as a client).</summary>
+ <content type="xhtml">
+ <div xmlns="http://www.w3.org/1999/xhtml">
+ <h1 style='display: inline' id='loadbars-resurrected-from-perl-to-go-after-15-years'>Loadbars resurrected: From Perl to Go after 15 years</h1><br />
+<br />
+<span>Who remembers Loadbars? The small, humble server load monitoring tool I wrote back in November 2010 as a Perl+SDL project during my first job after graduating from university as a Linux Sysadmin. That was over 15 years ago. After being effectively dead for more than a decade, Loadbars is working again -- rewritten in Go from Perl with the help of AI (Claude Code), and it even works on macOS now (as a client).</span><br />
+<br />
+<a href='./loadbars-resurrected-from-perl-to-go/loadbars.gif'><img alt='Loadbars in action' title='Loadbars in action' src='./loadbars-resurrected-from-perl-to-go/loadbars.gif' /></a><br />
+<br />
+<a class='textlink' href='https://codeberg.org/snonux/loadbars'>Loadbars on Codeberg</a><br />
+<br />
+<h2 style='display: inline' id='table-of-contents'>Table of Contents</h2><br />
+<br />
+<ul>
+<li><a href='#loadbars-resurrected-from-perl-to-go-after-15-years'>Loadbars resurrected: From Perl to Go after 15 years</a></li>
+<li>⇢ <a href='#what-loadbars-is-and-isn-t'>What Loadbars is (and isn&#39;t)</a></li>
+<li>⇢ <a href='#why-the-rewrite-was-necessary'>Why the rewrite was necessary</a></li>
+<li>⇢ <a href='#a-brief-history'>A brief history</a></li>
+<li>⇢ <a href='#features'>Features</a></li>
+<li>⇢ ⇢ <a href='#cpu-monitoring'>CPU monitoring</a></li>
+<li>⇢ ⇢ <a href='#memory-monitoring'>Memory monitoring</a></li>
+<li>⇢ ⇢ <a href='#network-monitoring'>Network monitoring</a></li>
+<li>⇢ ⇢ <a href='#all-hotkeys'>All hotkeys</a></li>
+<li>⇢ ⇢ <a href='#ssh-and-multi-host-support'>SSH and multi-host support</a></li>
+<li>⇢ ⇢ <a href='#config-file'>Config file</a></li>
+<li>⇢ ⇢ <a href='#macos-support'>macOS support</a></li>
+<li>⇢ <a href='#building-from-source'>Building from source</a></li>
+<li>⇢ <a href='#tested-platforms'>Tested platforms</a></li>
+<li>⇢ <a href='#future-proof-with-go'>Future-proof with Go</a></li>
+<li>⇢ <a href='#the-ai-rewrite-experience'>The AI rewrite experience</a></li>
+</ul><br />
+<h2 style='display: inline' id='what-loadbars-is-and-isn-t'>What Loadbars is (and isn&#39;t)</h2><br />
+<br />
+<span>Loadbars is a real-time server load monitoring tool. It connects to one or more Linux hosts via SSH and shows CPU, memory, and network usage as vertical colored bars in an SDL window. You can also run it locally without SSH. It shows the current state only -- like <span class='inlinecode'>top</span> or <span class='inlinecode'>vmstat</span>, but visual and across multiple hosts at once. All you need is a working SSH connection through an SSH Agent.</span><br />
+<br />
+<span>It is not a tool for collecting loads and drawing graphs for later analysis. There is no history, no recording, no database. Tools like Prometheus or Grafana require significant setup time before producing results. Loadbars lets you observe the current state immediately. You install one binary, point it at your servers, and see what&#39;s happening right now.</span><br />
+<br />
+<pre>
+┌─ Loadbars 0.9.0 ──────────────────────────────────────────┐
+│ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ████ ████ ████ ██ ████ ████ ████ ██ ░░██ ░░██ │
+│ ▓▓▓▓ ▓▓▓▓ ▓▓▓▓ ▓▓ ▓▓▓▓ ▓▓▓▓ ▓▓▓▓ ▓▓ ░░▓▓ ░░▓▓ │
+│ CPU cpu0 cpu1 mem CPU cpu0 cpu1 mem net net │
+│ └──── host1 ────┘ └──── host2 ────┘ │
+└───────────────────────────────────────────────────────────┘
+</pre>
+<br />
+<h2 style='display: inline' id='why-the-rewrite-was-necessary'>Why the rewrite was necessary</h2><br />
+<br />
+<span>I&#39;d have liked to have kept the Perl version. Perl was the first language I learned properly, and I have a soft spot for it. But there was an (for me) unresolvable multithreading issue related to recent Perl and SDL library versions. Perl&#39;s <span class='inlinecode'>ithreads</span> and SDL doesn&#39;t work reliably anymore, and debugging decade-old thread-safety issues in XS bindings is not a productive use of time.</span><br />
+<br />
+<span>I actually tried to fix the Perl version first. I had Claude Code (CLI, running Opus 5.3) attempt to resolve the segfault involving Perl&#39;s multi-threading and SDL. It couldn&#39;t—the issue is deep in the XS bindings and not something you can fix from Perl-land (nor did I want to invest my own time in it either). So the more pragmatic thing to do was to let Claude Code rewrite the whole thing in Go instead. That worked without any major issues. The Go version is cleaner, faster to build, easier to deploy (single static binary), and now has proper unit tests.</span><br />
+<br />
+<span>The important thing: for the user, nothing changes. The rewrite&#39;s usage, look, and feel are de-facto identical to the old Perl version. The same hotkeys, the same bar layout, the same colors, the same config file format. If you used Loadbars ten years ago, you can pick up the new version and everything works exactly as you remember. The only difference is under the hood.</span><br />
+<br />
+<h2 style='display: inline' id='a-brief-history'>A brief history</h2><br />
+<br />
+<span>The first commit is from November 5, 2010—over 13 years ago. Back then, it was called <span class='inlinecode'>cpuload</span> and was a quick Perl+SDL hack I wrote at work to keep an eye on a fleet of Linux servers. It grew into Loadbars over the following weeks, gaining memory and network monitoring, ClusterSSH integration, and a config file. The last meaningful Perl development was around 2013. Around that time, there were already a couple of colleagues who used Loadbars frequently. But then I changed my job role and later even jobs, and I stopped development of Loadbars.</span><br />
+<br />
+<span>For the next decade, it sat dormant. I occasionally thought about reviving it, but Perl+SDL threading issues made it impractical. In February 2026, I finally sat down with Claude Code and let it rewrite the whole thing in Go in a single session.</span><br />
+<br />
+<h2 style='display: inline' id='features'>Features</h2><br />
+<br />
+<h3 style='display: inline' id='cpu-monitoring'>CPU monitoring</h3><br />
+<br />
+<span>CPU usage is shown as vertical colored bars. Each bar is stacked from bottom to top with the following segments:</span><br />
+<br />
+<ul>
+<li>System (blue) -- kernel CPU time</li>
+<li>User (yellow) -- user-space CPU time; turns dark yellow above 50%, orange above 70%</li>
+<li>Nice (green) -- low-priority user processes</li>
+<li>Idle (black) -- unused CPU</li>
+<li>IOwait (purple) -- waiting for disk I/O</li>
+<li>IRQ / SoftIRQ (white) -- interrupt handling</li>
+<li>Guest (red) -- time spent running virtual CPUs</li>
+<li>Steal (red) -- time stolen by the hypervisor</li>
+</ul><br />
+<span>Press <span class='inlinecode'>1</span> to toggle between one aggregate bar per host and one bar per core. Press <span class='inlinecode'>e</span> for extended mode, which adds a 1px peak line showing the maximum system+user percentage over the last N samples.</span><br />
+<br />
+<h3 style='display: inline' id='memory-monitoring'>Memory monitoring</h3><br />
+<br />
+<span>Press <span class='inlinecode'>2</span> to toggle memory bars. Each host gets one bar split in two halves:</span><br />
+<br />
+<ul>
+<li>Left half: RAM usage (dark grey = used, black = free)</li>
+<li>Right half: Swap usage (grey = used, black = free)</li>
+</ul><br />
+<h3 style='display: inline' id='network-monitoring'>Network monitoring</h3><br />
+<br />
+<span>Press <span class='inlinecode'>3</span> to toggle network bars. Loadbars sums RX and TX bytes across all non-loopback interfaces (e.g. <span class='inlinecode'>eth0</span>, <span class='inlinecode'>wlan0</span>, <span class='inlinecode'>enp0s3</span>) and shows the combined total. Loopback (<span class='inlinecode'>lo</span>) is always excluded. Each net bar has two halves:</span><br />
+<br />
+<ul>
+<li>Left half: RX (received) growing from the top (light green)</li>
+<li>Right half: TX (transmitted) growing from the bottom (light green)</li>
+</ul><br />
+<span>Network utilization is shown as a percentage of the configured link speed. The default link speed is <span class='inlinecode'>gbit</span> (1 Gbps). Change it with <span class='inlinecode'>--netlink</span> or in the config file. Press <span class='inlinecode'>f</span>/<span class='inlinecode'>v</span> to scale the link speed up or down during runtime (cycles through mbit, 10mbit, 100mbit, gbit, 10gbit).</span><br />
+<br />
+<span>If the net bar is red, it means no non-loopback interface was found on that host.</span><br />
+<br />
+<h3 style='display: inline' id='all-hotkeys'>All hotkeys</h3><br />
+<br />
+<pre>
+Key Action
+───── ──────────────────────────────────────────────────
+1 Toggle CPU cores (aggregate vs per-core bars)
+2 Toggle memory bars
+3 Toggle network bars (aggregated across interfaces)
+e Toggle extended display (peak line on CPU bars)
+h Print hotkey list to stdout
+q Quit
+w Write current settings to ~/.loadbarsrc
+a / y Increase / decrease CPU average samples
+d / c Increase / decrease net average samples
+f / v Link scale up / down (net utilization reference)
+Arrows Resize window (left/right: width, up/down: height)
+</pre>
+<br />
+<h3 style='display: inline' id='ssh-and-multi-host-support'>SSH and multi-host support</h3><br />
+<br />
+<span>Loadbars connects to remote hosts via SSH using public key authentication. No agent or special setup is needed on the remote side -- Loadbars embeds a small bash script in the binary and runs it via <span class='inlinecode'>bash -s</span> over SSH. The remote hosts only need bash and <span class='inlinecode'>/proc</span> (i.e. Linux).</span><br />
+<br />
+<pre>
+loadbars --hosts server1,server2,server3
+
+loadbars --hosts root@server1,root@server2
+
+loadbars servername{01..50}.example.com --showcores 1
+</pre>
+<br />
+<span>Shell brace expansion works for specifying ranges of hosts. You can also use ClusterSSH cluster definitions from <span class='inlinecode'>/etc/clusters</span>:</span><br />
+<br />
+<pre>
+loadbars --cluster production
+</pre>
+<br />
+<span>When no hosts are given, Loadbars runs locally on <span class='inlinecode'>localhost</span> without SSH.</span><br />
+<br />
+<h3 style='display: inline' id='config-file'>Config file</h3><br />
+<br />
+<span>Loadbars reads <span class='inlinecode'>~/.loadbarsrc</span> on startup. Any option from <span class='inlinecode'>--help</span> can be set there without the leading <span class='inlinecode'>--</span>. Comments use <span class='inlinecode'>#</span>. Press <span class='inlinecode'>w</span> during runtime to write the current settings to the config file.</span><br />
+<br />
+<pre>
+showcores=1
+showmem=1
+shownet=1
+extended=1
+netlink=gbit
+cpuaverage=10
+netaverage=15
+height=150
+barwidth=1200
+</pre>
+<br />
+<h3 style='display: inline' id='macos-support'>macOS support</h3><br />
+<br />
+<span>macOS is supported as a client for monitoring remote Linux servers via SSH. Local monitoring on macOS is not supported because it requires the <span class='inlinecode'>/proc</span> filesystem. The SDL window is automatically brought to the foreground on macOS.</span><br />
+<br />
+<h2 style='display: inline' id='building-from-source'>Building from source</h2><br />
+<br />
+<span>Loadbars requires Go 1.25+ and SDL2. Install the SDL2 development libraries for your platform:</span><br />
+<br />
+<pre>
+# Fedora / RHEL / CentOS
+sudo dnf install SDL2-devel
+
+# macOS
+brew install sdl2
+</pre>
+<br />
+<span>Then build with Mage (recommended) or plain Go:</span><br />
+<br />
+<pre>
+mage build
+./loadbars --hosts localhost
+
+# or without Mage:
+go build -o loadbars ./cmd/loadbars
+</pre>
+<br />
+<span>Install to <span class='inlinecode'>~/go/bin</span>:</span><br />
+<br />
+<pre>
+mage install
+</pre>
+<br />
+<span>Run tests:</span><br />
+<br />
+<pre>
+mage test
+# or: go test ./...
+</pre>
+<br />
+<h2 style='display: inline' id='tested-platforms'>Tested platforms</h2><br />
+<br />
+<ul>
+<li>Fedora Linux 43 and most modern Linux distributions (RHEL, CentOS, Ubuntu, Debian, etc.)</li>
+<li>macOS (Darwin) as a client connecting to remote Linux servers via SSH</li>
+</ul><br />
+<span>Remote hosts must be Linux with <span class='inlinecode'>/proc</span> and bash.</span><br />
+<br />
+<h2 style='display: inline' id='future-proof-with-go'>Future-proof with Go</h2><br />
+<br />
+<span>One of the reasons I chose Go for the rewrite is Go&#39;s compatibility promise. The Go 1 compatibility guarantee means that code written today will continue to compile and work with future Go releases. No more bitrotted XS bindings, no more <span class='inlinecode'>ithreads</span> headaches, no more hunting for compatible versions of SDL Perl modules.</span><br />
+<br />
+<span>The Go SDL2 bindings (go-sdl2) are actively maintained, and SDL2 itself is a stable, well-supported library. The entire application compiles to a single static binary with no runtime dependencies beyond SDL2. Deploy it anywhere, run it for years.</span><br />
+<br />
+<h2 style='display: inline' id='the-ai-rewrite-experience'>The AI rewrite experience</h2><br />
+<br />
+<span>This resurrection would not have been really possible without the help of AI. The rewrite was done with Claude Code CLI (Anthropic&#39;s coding agent) running Claude Opus 5.3. I pointed it at the Perl source, and let it produce the Go equivalent. The process was surprisingly smooth -- the rewrite worked without any major issues. There were some minor bugs (such as network bars not showing up initially, and/or some pixel errors in the bars), but they were sorted by Claude by providing screenshots of the problems.</span><br />
+<br />
+<span>E-Mail your comments to <span class='inlinecode'>paul@nospam.buetow.org</span> :-)</span><br />
+<br />
+<span>Other related posts:</span><br />
+<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 Loadbars resurrected: From Perl to Go after 15 years (You are currently reading this)</a><br />
+<a class='textlink' href='./2025-11-02-perl-new-features-and-foostats.html'>2025-11-02 Perl New Features and Foostats</a><br />
+<a class='textlink' href='./2025-09-14-bash-golf-part-4.html'>2025-09-14 Bash Golf Part 4</a><br />
+<a class='textlink' href='./2025-03-05-sharing-on-social-media-with-gos.html'>2025-03-05 Sharing on Social Media with Gos v1.0.0</a><br />
+<a class='textlink' href='./2024-03-03-a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang.html'>2024-03-03 A fine Fyne Android app for quickly logging ideas programmed in Go</a><br />
+<a class='textlink' href='./2023-12-10-bash-golf-part-3.html'>2023-12-10 Bash Golf Part 3</a><br />
+<a class='textlink' href='./2023-06-01-kiss-server-monitoring-with-gogios.html'>2023-06-01 KISS server monitoring with Gogios</a><br />
+<a class='textlink' href='./2022-05-27-perl-is-still-a-great-choice.html'>2022-05-27 Perl is still a great choice</a><br />
+<a class='textlink' href='./2022-01-01-bash-golf-part-2.html'>2022-01-01 Bash Golf Part 2</a><br />
+<a class='textlink' href='./2021-11-29-bash-golf-part-1.html'>2021-11-29 Bash Golf Part 1</a><br />
+<a class='textlink' href='./2011-05-07-perl-daemon-service-framework.html'>2011-05-07 Perl Daemon (Service Framework)</a><br />
+<a class='textlink' href='./2008-06-26-perl-poetry.html'>2008-06-26 Perl Poetry</a><br />
+<br />
+<a class='textlink' href='../'>Back to the main site</a><br />
+ </div>
+ </content>
+ </entry>
+ <entry>
+ <title>TIL: Meta slash-commands for reusable AI prompts and context</title>
+ <link href="https://foo.zone/gemfeed/2026-02-14-til-meta-slash-commands-for-ai-workflows.html" />
+ <id>https://foo.zone/gemfeed/2026-02-14-til-meta-slash-commands-for-ai-workflows.html</id>
+ <updated>2026-02-14T14:00:00+02:00</updated>
+ <author>
+ <name>Paul Buetow aka snonux</name>
+ <email>paul@dev.buetow.org</email>
+ </author>
+ <summary>Short post in 'This week I learned' style: what I tried, why it worked, and how you can replicate it. Format: Problem → Approach → Copy/paste → Result → Gotchas. Full reference for the meta-commands lives in a separate post.</summary>
+ <content type="xhtml">
+ <div xmlns="http://www.w3.org/1999/xhtml">
+ <h1 style='display: inline' id='til-meta-slash-commands-for-reusable-ai-prompts-and-context'>TIL: Meta slash-commands for reusable AI prompts and context</h1><br />
+<br />
+<span class='quote'>Published at 2026-02-14T14:00:00+02:00</span><br />
+<br />
+<span>Short post in "This week I learned" style: what I tried, why it worked, and how you can replicate it. Format: Problem → Approach → Copy/paste → Result → Gotchas. Full reference for the meta-commands lives in a separate post.</span><br />
+<br />
+<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>Full reference: Meta slash-commands to manage prompts and context for coding agents</a><br />
+<br />
+<h2 style='display: inline' id='til'>TIL</h2><br />
+<br />
+<h3 style='display: inline' id='problem'>Problem</h3><br />
+<br />
+<span>When I use a coding agent (Cursor Agent, Claude Code CLI, Ampcode, etc.), I repeat the same requests: "review this function," "explain this error," "add tests for this module," "format this as a blog post." Typing long prompts from scratch is tedious; ad-hoc prompts are easy to forget. I also keep pasting the same background (API conventions, project rules, infra notes) into every session so the agent doesn&#39;t guess blindly.</span><br />
+<br />
+<h3 style='display: inline' id='approach'>Approach</h3><br />
+<br />
+<span>Treat prompts and context as first-class artefacts: store them as markdown files (one per slash-command or per context) in a dotfiles repo. Use a small set of *meta* slash-commands so the agent itself creates, updates, and deletes these files from the conversation—no hand-editing. Two kinds of artefacts:</span><br />
+<br />
+<ul>
+<li>Commands — Reusable workflows (e.g. review-code, explain-error). Live in <span class='inlinecode'>commands/</span> as <span class='inlinecode'>.md</span> files.</li>
+<li>Context — Reusable background (API guidelines, runbooks, personas). Live in <span class='inlinecode'>context/</span> as <span class='inlinecode'>.md</span> files; you *load* one at session start so the agent has it in mind.</li>
+</ul><br />
+<h3 style='display: inline' id='copypaste'>Copy/paste</h3><br />
+<br />
+<span>Minimal workflow:</span><br />
+<br />
+<pre>
+/load-context api-guidelines
+</pre>
+<br />
+<span>Then ask the agent to implement a feature or fix a bug; it already has the guidelines.</span><br />
+<br />
+<span>To turn something you just did into a reusable command:</span><br />
+<br />
+<pre>
+/create-command review-code
+</pre>
+<br />
+<span>Full command reference (all meta-commands, parameters, examples):</span><br />
+<br />
+<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>Meta slash-commands — full reference</a><br />
+<br />
+<h3 style='display: inline' id='result'>Result</h3><br />
+<br />
+<span>No more retyping long prompts; same prompt library across Cursor Agent, Claude Code CLI, OpenCode, Ampcode. Context is load-on-demand per session instead of pasting walls of text. Everything is versioned in git and synced across machines.</span><br />
+<br />
+<h3 style='display: inline' id='gotchas'>Gotchas</h3><br />
+<br />
+<ul>
+<li>Requires an agent that supports custom slash-commands (or reading prompt files from disk).</li>
+<li>Context is explicit: you must run <span class='inlinecode'>/load-context &lt;name&gt;</span> at session start; it&#39;s not implicit like some "skills" systems.</li>
+<li>A flat directory of commands can grow; if it gets unwieldy, consider grouping by skill or exposing via an MCP server later.</li>
+</ul><br />
+<h2 style='display: inline' id='beforeafter'>Before/After</h2><br />
+<br />
+<ul>
+<li>Before: Retyping or pasting long prompts each time; pasting API/project context into every session; prompts scattered and inconsistent across tools.</li>
+<li>After: <span class='inlinecode'>/load-context &lt;name&gt;</span> once per session; <span class='inlinecode'>/&lt;command&gt;</span> for repeatable tasks; commands and context in git, same library across agents.</li>
+</ul><br />
+<h2 style='display: inline' id='workflow-recipe'>Workflow recipe</h2><br />
+<br />
+<ul>
+<li>Steps: (1) Create or update context/commands via meta-commands when you have something worth reusing. (2) Start a session → run <span class='inlinecode'>/load-context &lt;name&gt;</span>. (3) Use slash-commands or ask ad-hoc; agent has background and consistent prompts.</li>
+<li>Tools: Cursor Agent (CLI), Claude Code CLI, OpenCode, Ampcode; markdown in e.g. <span class='inlinecode'>~/Notes/Prompts/commands/</span> and <span class='inlinecode'>~/Notes/Prompts/context/</span>.</li>
+<li>Impact: Saves retyping and keeps prompts consistent; one-time cost is creating the first context/command with the agent.</li>
+</ul><br />
+<h2 style='display: inline' id='micro-template-quick-reference'>Micro-template (quick reference)</h2><br />
+<br />
+<span>| Meta-command | Purpose | Good for |</span><br />
+<span>|--------------------|--------------------------------|-------------------------------------------|</span><br />
+<span>| /create-command | Create new slash-command | Turn current or recurring tasks into one |</span><br />
+<span>| /update-command | Edit existing slash-command | Refine after use |</span><br />
+<span>| /delete-command | Remove slash-command file | Clean up unused commands |</span><br />
+<span>| /create-context | Create new context file | Capture project/infra knowledge once |</span><br />
+<span>| /update-context | Edit existing context file | Keep context up to date |</span><br />
+<span>| /delete-context | Remove context file | Remove outdated context |</span><br />
+<span>| /load-context | Load context into conversation | Give agent background before tasks |</span><br />
+<br />
+<span>Example usage: <span class='inlinecode'>/load-context api-guidelines</span>, <span class='inlinecode'>/create-command review-code</span>, <span class='inlinecode'>/update-command review-code</span>. Full details and examples in the main post linked above.</span><br />
+<br />
+<span>Other related posts:</span><br />
+<br />
+<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>2026-02-14 Meta slash-commands to manage prompts and context for coding agents</a><br />
+<a class='textlink' href='./2026-02-02-tmux-popup-editor-for-cursor-agent-prompts.html'>2026-02-02 A tmux popup editor for Cursor Agent CLI prompts</a><br />
+<br />
+<span>E-Mail your comments to <span class='inlinecode'>paul@nospam.buetow.org</span> :-)</span><br />
+<br />
+<a class='textlink' href='../'>Back to the main site</a><br />
+ </div>
+ </content>
+ </entry>
+ <entry>
<title>Meta slash-commands to manage prompts and context for coding agents</title>
<link href="https://foo.zone/gemfeed/2026-02-14-meta-slash-commands-for-prompts-and-context.html" />
<id>https://foo.zone/gemfeed/2026-02-14-meta-slash-commands-for-prompts-and-context.html</id>
@@ -20,6 +367,8 @@
<div xmlns="http://www.w3.org/1999/xhtml">
<h1 style='display: inline' id='meta-slash-commands-to-manage-prompts-and-context-for-coding-agents'>Meta slash-commands to manage prompts and context for coding agents</h1><br />
<br />
+<span class='quote'>Published at 2026-02-14T13:44:45+02:00</span><br />
+<br />
<span>I work on many small, repeatable tasks. Instead of retyping the same instructions every time, I want to turn successful prompts into reusable slash-commands and keep background knowledge in loadable context files. This post describes a set of *meta* slash-commands: commands that create, update, and delete other commands and context files. They live as markdown in a dotfiles repo and work with any coding agent that supports slash-commands—Claude Code CLI, Cursor Agent, OpenCode, Ampcode, and others.</span><br />
<br />
<pre>
@@ -240,7 +589,8 @@
<br />
<span>Other related posts:</span><br />
<br />
-<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>2026-02-14 Meta slash-commands to manage prompts and context (You are currently reading this)</a><br />
+<a class='textlink' href='./2026-02-14-til-meta-slash-commands-for-ai-workflows.html'>2026-02-14 TIL: Meta slash-commands for reusable AI prompts and context</a><br />
+<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>2026-02-14 Meta slash-commands to manage prompts and context for coding agents (You are currently reading this)</a><br />
<a class='textlink' href='./2026-02-02-tmux-popup-editor-for-cursor-agent-prompts.html'>2026-02-02 A tmux popup editor for Cursor Agent CLI prompts</a><br />
<br />
<span>E-Mail your comments to <span class='inlinecode'>paul@nospam.buetow.org</span> :-)</span><br />
@@ -4316,6 +4666,7 @@ http://www.gnu.org/software/src-highlite -->
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 Loadbars resurrected: From Perl to Go after 15 years</a><br />
<a class='textlink' href='./2025-11-02-perl-new-features-and-foostats.html'>2025-11-02 Perl New Features and Foostats (You are currently reading this)</a><br />
<a class='textlink' href='./2023-05-01-unveiling-guprecords:-uptime-records-with-raku.html'>2023-05-01 Unveiling <span class='inlinecode'>guprecords.raku</span>: Global Uptime Records with Raku</a><br />
<a class='textlink' href='./2022-05-27-perl-is-still-a-great-choice.html'>2022-05-27 Perl is still a great choice</a><br />
@@ -7358,6 +7709,7 @@ content = "{CODE}"
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-14-til-meta-slash-commands-for-ai-workflows.html'>2026-02-14 TIL: Meta slash-commands for reusable AI prompts and context</a><br />
<a class='textlink' href='./2025-08-05-local-coding-llm-with-ollama.html'>2025-08-05 Local LLM for Coding with Ollama on macOS (You are currently reading this)</a><br />
<a class='textlink' href='./2025-06-22-task-samurai.html'>2025-06-22 Task Samurai: An agentic coding learning experiment</a><br />
<br />
@@ -10431,6 +10783,7 @@ http://www.gnu.org/software/src-highlite -->
<br />
<span>Other related posts are:</span><br />
<br />
+<a class='textlink' href='./2026-02-14-til-meta-slash-commands-for-ai-workflows.html'>2026-02-14 TIL: Meta slash-commands for reusable AI prompts and context</a><br />
<a class='textlink' href='./2025-08-05-local-coding-llm-with-ollama.html'>2025-08-05 Local LLM for Coding with Ollama on macOS</a><br />
<a class='textlink' href='./2025-06-22-task-samurai.html'>2025-06-22 Task Samurai: An agentic coding learning experiment (You are currently reading this)</a><br />
<br />
@@ -18063,433 +18416,4 @@ http://www.gnu.org/software/src-highlite -->
</div>
</content>
</entry>
- <entry>
- <title>KISS high-availability with OpenBSD</title>
- <link href="https://foo.zone/gemfeed/2024-04-01-KISS-high-availability-with-OpenBSD.html" />
- <id>https://foo.zone/gemfeed/2024-04-01-KISS-high-availability-with-OpenBSD.html</id>
- <updated>2024-03-30T22:12:56+02:00</updated>
- <author>
- <name>Paul Buetow aka snonux</name>
- <email>paul@dev.buetow.org</email>
- </author>
- <summary>I have always wanted a highly available setup for my personal websites. I could have used off-the-shelf hosting solutions or hosted my sites in an AWS S3 bucket. I have used technologies like (in unsorted and slightly unrelated order) BGP, LVS/IPVS, ldirectord, Pacemaker, STONITH, scripted VIP failover via ARP, heartbeat, heartbeat2, Corosync, keepalived, DRBD, and commercial F5 Load Balancers for high availability at work. </summary>
- <content type="xhtml">
- <div xmlns="http://www.w3.org/1999/xhtml">
- <h1 style='display: inline' id='kiss-high-availability-with-openbsd'>KISS high-availability with OpenBSD</h1><br />
-<br />
-<span class='quote'>Published at 2024-03-30T22:12:56+02:00</span><br />
-<br />
-<span>I have always wanted a highly available setup for my personal websites. I could have used off-the-shelf hosting solutions or hosted my sites in an AWS S3 bucket. I have used technologies like (in unsorted and slightly unrelated order) BGP, LVS/IPVS, ldirectord, Pacemaker, STONITH, scripted VIP failover via ARP, heartbeat, heartbeat2, Corosync, keepalived, DRBD, and commercial F5 Load Balancers for high availability at work. </span><br />
-<br />
-<span>But still, my personal sites were never highly available. All those technologies are great for professional use, but I was looking for something much more straightforward for my personal space - something as KISS (keep it simple and stupid) as possible.</span><br />
-<br />
-<span>It would be fine if my personal website wasn&#39;t highly available, but the geek in me wants it anyway.</span><br />
-<br />
-<span class='quote'>PS: ASCII-art below reflects an OpenBSD under-water world with all the tools available in the base system.</span><br />
-<br />
-<pre>
-Art by Michael J. Penick (mod. by Paul B.)
- ACME-sky
- __________
- / nsd tower\ (
- /____________\ (\) awk-ward
- |:_:_:_:_:_| )) plant
- |_:_,--.:_:| dig-bubble (\// )
- |:_:|__|_:_| relayd-castle _ ) )) ((
- _ |_ _ :_:| _ _ _ (_) (((( /)\`
- | |_| |_| | _| | |_| |_| | o \\)) (( (
- \_:_:_:_:/|_|_|_|\:_:_:_:_/ . (( ))))
- |_,-._:_:_:_:_:_:_:_.-,_| )) ((//
- |:|_|:_:_:,---,:_:_:|_|:| ,-. )/
- |_:_:_:_,&#39;puffy `,_:_:_:_| _ o ,;&#39;))((
- |:_:_:_/ _ | _ \_:_:_:| (_O (( ))
-_____|_:_:_| (o)-(o) |_:_:_|--&#39;`-. ,--. ksh under-water (((\&#39;/
- &#39;, ;|:_:_:| -( .-. )- |:_:_:| &#39;, ; `--._\ /,---.~ goat \`))
-. ` |_:_:_| \`-&#39;/ |_:_:_|. ` . ` /()\.__( ) .,-----&#39;`-\(( sed-root
- &#39;, ;|:_:_:| `-&#39; |:_:_:| &#39;, ; &#39;, ; `--&#39;| \ &#39;, ; &#39;, ; &#39;,&#39;)).,--
-. ` MJP ` . ` . ` . ` . httpd-soil ` . . ` . ` . ` . ` . `
- &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ; &#39;, ;
-
-</pre>
-<br />
-<h2 style='display: inline' id='table-of-contents'>Table of Contents</h2><br />
-<br />
-<ul>
-<li><a href='#kiss-high-availability-with-openbsd'>KISS high-availability with OpenBSD</a></li>
-<li>⇢ <a href='#my-auto-failover-requirements'>My auto-failover requirements</a></li>
-<li>⇢ <a href='#my-ha-solution'>My HA solution</a></li>
-<li>⇢ ⇢ <a href='#only-openbsd-base-installation-required'>Only OpenBSD base installation required</a></li>
-<li>⇢ ⇢ <a href='#fairly-cheap-and-geo-redundant'>Fairly cheap and geo-redundant</a></li>
-<li>⇢ ⇢ <a href='#failover-time-and-split-brain'>Failover time and split-brain</a></li>
-<li>⇢ ⇢ <a href='#failover-support-for-multiple-protocols'>Failover support for multiple protocols</a></li>
-<li>⇢ ⇢ <a href='#let-s-encrypt-tls-certificates'>Let&#39;s encrypt TLS certificates</a></li>
-<li>⇢ ⇢ <a href='#monitoring'>Monitoring</a></li>
-<li>⇢ ⇢ <a href='#rex-automation'>Rex automation</a></li>
-<li>⇢ <a href='#more-ha'>More HA</a></li>
-</ul><br />
-<h2 style='display: inline' id='my-auto-failover-requirements'>My auto-failover requirements</h2><br />
-<br />
-<ul>
-<li>Be OpenBSD-based (I prefer OpenBSD because of the cleanliness and good documentation) and rely on as few external packages as possible. </li>
-<li>Don&#39;t rely on the hottest and newest tech (don&#39;t want to migrate everything to a new and fancier technology next month already!).</li>
-<li>It should be reasonably cheap. I want to avoid paying a premium for floating IPs or fancy Elastic Load Balancers.</li>
-<li>It should be geo-redundant. </li>
-<li>It&#39;s fine if my sites aren&#39;t reachable for five or ten minutes every other month. Due to their static nature, I don&#39;t care if there&#39;s a split-brain scenario where some requests reach one server and other requests reach another server.</li>
-<li>Failover should work for both HTTP/HTTPS and Gemini protocols. My self-hosted MTAs and DNS servers should also be highly available.</li>
-<li>Let&#39;s Encrypt TLS certificates should always work (before and after a failover).</li>
-<li>Have good monitoring in place so I know when a failover was performed and when something went wrong with the failover.</li>
-<li>Don&#39;t configure everything manually. The configuration should be automated and reproducible.</li>
-</ul><br />
-<h2 style='display: inline' id='my-ha-solution'>My HA solution</h2><br />
-<br />
-<h3 style='display: inline' id='only-openbsd-base-installation-required'>Only OpenBSD base installation required</h3><br />
-<br />
-<span>My HA solution for Web and Gemini is based on DNS (OpenBSD&#39;s <span class='inlinecode'>nsd</span>) and a simple shell script (OpenBSD&#39;s <span class='inlinecode'>ksh</span> and some little <span class='inlinecode'>sed</span> and <span class='inlinecode'>awk</span> and <span class='inlinecode'>grep</span>). All software used here is part of the OpenBSD base system and no external package needs to be installed - OpenBSD is a complete operating system.</span><br />
-<br />
-<a class='textlink' href='https://man.OpenBSD.org/nsd.8'>https://man.OpenBSD.org/nsd.8</a><br />
-<a class='textlink' href='https://man.OpenBSD.org/ksh'>https://man.OpenBSD.org/ksh</a><br />
-<a class='textlink' href='https://man.OpenBSD.org/awk'>https://man.OpenBSD.org/awk</a><br />
-<a class='textlink' href='https://man.OpenBSD.org/sed'>https://man.OpenBSD.org/sed</a><br />
-<a class='textlink' href='https://man.OpenBSD.org/dig'>https://man.OpenBSD.org/dig</a><br />
-<a class='textlink' href='https://man.OpenBSD.org/ftp'>https://man.OpenBSD.org/ftp</a><br />
-<a class='textlink' href='https://man.OpenBSD.org/cron'>https://man.OpenBSD.org/cron</a><br />
-<br />
-<span>I also used the <span class='inlinecode'>dig</span> (for DNS checks) and <span class='inlinecode'>ftp</span> (for HTTP/HTTPS checks) programs. </span><br />
-<br />
-<span>The DNS failover is performed automatically between the two OpenBSD VMs involved (my setup doesn&#39;t require any quorum for a failover, so there isn&#39;t a need for a 3rd VM). The <span class='inlinecode'>ksh</span> script, executed once per minute via CRON (on both VMs), performs a health check to determine whether the current master node is available. If the current master isn&#39;t available (no HTTP response as expected), a failover is performed to the standby VM: </span><br />
-<br />
-<!-- Generator: GNU source-highlight 3.1.9
-by Lorenzo Bettini
-http://www.lorenzobettini.it
-http://www.gnu.org/software/src-highlite -->
-<pre><i><font color="silver">#!/bin/ksh</font></i>
-
-ZONES_DIR=/var/nsd/zones/master/
-DEFAULT_MASTER=fishfinger.buetow.org
-DEFAULT_STANDBY=blowfish.buetow.org
-
-determine_master_and_standby () {
- <b><u><font color="#000000">local</font></u></b> master=$DEFAULT_MASTER
- <b><u><font color="#000000">local</font></u></b> standby=$DEFAULT_STANDBY
-
- .
- .
- .
-
- <b><u><font color="#000000">local</font></u></b> -i health_ok=<font color="#000000">1</font>
- <b><u><font color="#000000">if</font></u></b> ! ftp -<font color="#000000">4</font> -o - https://$master/index.txt | grep -q <font color="#808080">"Welcome to $master"</font>; <b><u><font color="#000000">then</font></u></b>
- echo <font color="#808080">"https://$master/index.txt IPv4 health check failed"</font>
- health_ok=<font color="#000000">0</font>
- <b><u><font color="#000000">elif</font></u></b> ! ftp -<font color="#000000">6</font> -o - https://$master/index.txt | grep -q <font color="#808080">"Welcome to $master"</font>; <b><u><font color="#000000">then</font></u></b>
- echo <font color="#808080">"https://$master/index.txt IPv6 health check failed"</font>
- health_ok=<font color="#000000">0</font>
- <b><u><font color="#000000">fi</font></u></b>
- <b><u><font color="#000000">if</font></u></b> [ $health_ok -eq <font color="#000000">0</font> ]; <b><u><font color="#000000">then</font></u></b>
- <b><u><font color="#000000">local</font></u></b> tmp=$master
- master=$standby
- standby=$tmp
- <b><u><font color="#000000">fi</font></u></b>
-
- .
- .
- .
-}
-</pre>
-<br />
-<span>The failover scripts looks for the <span class='inlinecode'> ; Enable failover</span> string in the DNS zone files and swaps the <span class='inlinecode'>A</span> and <span class='inlinecode'>AAAA</span> records of the DNS entries accordingly:</span><br />
-<br />
-<!-- Generator: GNU source-highlight 3.1.9
-by Lorenzo Bettini
-http://www.lorenzobettini.it
-http://www.gnu.org/software/src-highlite -->
-<pre>fishfinger$ grep failover /var/nsd/zones/master/foo.zone.zone
- <font color="#000000">300</font> IN A <font color="#000000">46.23</font>.<font color="#000000">94.99</font> ; Enable failover
- <font color="#000000">300</font> IN AAAA 2a03:<font color="#000000">6000</font>:6f67:<font color="#000000">624</font>::<font color="#000000">99</font> ; Enable failover
-www <font color="#000000">300</font> IN A <font color="#000000">46.23</font>.<font color="#000000">94.99</font> ; Enable failover
-www <font color="#000000">300</font> IN AAAA 2a03:<font color="#000000">6000</font>:6f67:<font color="#000000">624</font>::<font color="#000000">99</font> ; Enable failover
-standby <font color="#000000">300</font> IN A <font color="#000000">23.88</font>.<font color="#000000">35.144</font> ; Enable failover
-standby <font color="#000000">300</font> IN AAAA 2a01:4f8:c17:20f1::<font color="#000000">42</font> ; Enable failover
-</pre>
-<br />
-<!-- Generator: GNU source-highlight 3.1.9
-by Lorenzo Bettini
-http://www.lorenzobettini.it
-http://www.gnu.org/software/src-highlite -->
-<pre>transform () {
- sed -E <font color="#808080">'</font>
-<font color="#808080"> /IN A .*; Enable failover/ {</font>
-<font color="#808080"> /^standby/! {</font>
-<font color="#808080"> s/^(.*) 300 IN A (.*) ; (.*)/</font>\1<font color="#808080"> 300 IN A '</font>$(cat /var/nsd/run/master_a)<font color="#808080">' ; </font>\3<font color="#808080">/;</font>
-<font color="#808080"> }</font>
-<font color="#808080"> /^standby/ {</font>
-<font color="#808080"> s/^(.*) 300 IN A (.*) ; (.*)/</font>\1<font color="#808080"> 300 IN A '</font>$(cat /var/nsd/run/standby_a)<font color="#808080">' ; </font>\3<font color="#808080">/;</font>
-<font color="#808080"> }</font>
-<font color="#808080"> }</font>
-<font color="#808080"> /IN AAAA .*; Enable failover/ {</font>
-<font color="#808080"> /^standby/! {</font>
-<font color="#808080"> s/^(.*) 300 IN AAAA (.*) ; (.*)/</font>\1<font color="#808080"> 300 IN AAAA '</font>$(cat /var/nsd/run/master_aaaa)<font color="#808080">' ; </font>\3<font color="#808080">/;</font>
-<font color="#808080"> }</font>
-<font color="#808080"> /^standby/ {</font>
-<font color="#808080"> s/^(.*) 300 IN AAAA (.*) ; (.*)/</font>\1<font color="#808080"> 300 IN AAAA '</font>$(cat /var/nsd/run/standby_aaaa)<font color="#808080">' ; </font>\3<font color="#808080">/;</font>
-<font color="#808080"> }</font>
-<font color="#808080"> }</font>
-<font color="#808080"> / ; serial/ {</font>
-<font color="#808080"> s/^( +) ([0-9]+) .*; (.*)/</font>\1<font color="#808080"> '</font>$(date +%s)<font color="#808080">' ; </font>\3<font color="#808080">/;</font>
-<font color="#808080"> }</font>
-<font color="#808080"> '</font>
-}
-</pre>
-<br />
-<span>After the failover, the script reloads <span class='inlinecode'>nsd</span> and performs a sanity check to see if DNS still works. If not, a rollback will be performed:</span><br />
-<br />
-<!-- Generator: GNU source-highlight 3.1.9
-by Lorenzo Bettini
-http://www.lorenzobettini.it
-http://www.gnu.org/software/src-highlite -->
-<pre><i><font color="silver">#! Race condition !#</font></i>
-
-<b><u><font color="#000000">if</font></u></b> [ -f $zone_file.bak ]; <b><u><font color="#000000">then</font></u></b>
- mv $zone_file.bak $zone_file
-<b><u><font color="#000000">fi</font></u></b>
-
-cat $zone_file | transform &gt; $zone_file.new.tmp
-
-grep -v <font color="#808080">' ; serial'</font> $zone_file.new.tmp &gt; $zone_file.new.noserial.tmp
-grep -v <font color="#808080">' ; serial'</font> $zone_file &gt; $zone_file.old.noserial.tmp
-
-echo <font color="#808080">"Has zone $zone_file changed?"</font>
-<b><u><font color="#000000">if</font></u></b> diff -u $zone_file.old.noserial.tmp $zone_file.new.noserial.tmp; <b><u><font color="#000000">then</font></u></b>
- echo <font color="#808080">"The zone $zone_file hasn't changed"</font>
- rm $zone_file.*.tmp
- <b><u><font color="#000000">return</font></u></b> <font color="#000000">0</font>
-<b><u><font color="#000000">fi</font></u></b>
-
-cp $zone_file $zone_file.bak
-mv $zone_file.new.tmp $zone_file
-rm $zone_file.*.tmp
-echo <font color="#808080">"Reloading nsd"</font>
-nsd-control reload
-
-<b><u><font color="#000000">if</font></u></b> ! zone_is_ok $zone; <b><u><font color="#000000">then</font></u></b>
- echo <font color="#808080">"Rolling back $zone_file changes"</font>
- cp $zone_file $zone_file.invalid
- mv $zone_file.bak $zone_file
- echo <font color="#808080">"Reloading nsd"</font>
- nsd-control reload
- zone_is_ok $zone
- <b><u><font color="#000000">return</font></u></b> <font color="#000000">3</font>
-<b><u><font color="#000000">fi</font></u></b>
-
-<b><u><font color="#000000">for</font></u></b> cleanup <b><u><font color="#000000">in</font></u></b> invalid bak; <b><u><font color="#000000">do</font></u></b>
- <b><u><font color="#000000">if</font></u></b> [ -f $zone_file.$cleanup ]; <b><u><font color="#000000">then</font></u></b>
- rm $zone_file.$cleanup
- <b><u><font color="#000000">fi</font></u></b>
-<b><u><font color="#000000">done</font></u></b>
-
-echo <font color="#808080">"Failover of zone $zone to $MASTER completed"</font>
-<b><u><font color="#000000">return</font></u></b> <font color="#000000">1</font>
-</pre>
-<br />
-<span>A non-zero return code (here, 3 when a rollback and 1 when a DNS failover was performed) will cause CRON to send an E-Mail with the whole script output.</span><br />
-<br />
-<span>The authorative nameserver for my domains runs on both VMs, and both are configured to be a "master" DNS server so that they have their own individual zone files, which can be changed independently. Otherwise, my setup wouldn&#39;t work. The side effect is that under a split-brain scenario (both VMs cannot see each other), both would promote themselves to master via their local DNS entries. More about that later, but that&#39;s fine in my use case.</span><br />
-<br />
-<span>Check out the whole script here:</span><br />
-<br />
-<a class='textlink' href='https://codeberg.org/snonux/conf/src/branch/master/frontends/scripts/dns-failover.ksh'>dns-failover.ksh</a><br />
-<br />
-<h3 style='display: inline' id='fairly-cheap-and-geo-redundant'>Fairly cheap and geo-redundant</h3><br />
-<br />
-<span>I am renting two small OpenBSD VMs: One at OpenBSD Amsterdam and the other at Hetzner Cloud. So, both VMs are hosted at another provider, in different IP subnets, and in different countries (the Netherlands and Germany).</span><br />
-<br />
-<a class='textlink' href='https://OpenBSD.Amsterdam'>https://OpenBSD.Amsterdam</a><br />
-<a class='textlink' href='https://www.Hetzner.cloud'>https://www.Hetzner.cloud</a><br />
-<br />
-<span>I only have a little traffic on my sites. I could always upload the static content to AWS S3 if I suddenly had to. But this will never be required.</span><br />
-<br />
-<span>A DNS-based failover is cheap, as there isn&#39;t any BGP or fancy load balancer to pay for. Small VMs also cost less than millions.</span><br />
-<br />
-<h3 style='display: inline' id='failover-time-and-split-brain'>Failover time and split-brain</h3><br />
-<br />
-<span>A DNS failover doesn&#39;t happen immediately. I&#39;ve configured a DNS TTL of <span class='inlinecode'>300</span> seconds, and the failover script checks once per minute whether to perform a failover or not. So, in total, a failover can take six minutes (not including other DNS caching servers somewhere in the interweb, but that&#39;s fine - eventually, all requests will resolve to the new master after a failover).</span><br />
-<br />
-<span>A split-brain scenario between the old master and the new master might happen. That&#39;s OK, as my sites are static, and there&#39;s no database to synchronise other than HTML, CSS, and images when the site is updated.</span><br />
-<br />
-<h3 style='display: inline' id='failover-support-for-multiple-protocols'>Failover support for multiple protocols</h3><br />
-<br />
-<span>With the DNS failover, HTTP, HTTPS, and Gemini protocols are failovered. This works because all domain virtual hosts are configured on either VM&#39;s <span class='inlinecode'>httpd</span> (OpenBSD&#39;s HTTP server) and <span class='inlinecode'>relayd</span> (it&#39;s also part of OpenBSD and I use it to TLS offload the Gemini protocol). So, both VMs accept requests for all the hosts. It&#39;s just a matter of the DNS entries, which VM receives the requests.</span><br />
-<br />
-<a class='textlink' href='https://man.OpenBSD.org/httpd.8'>https://man.OpenBSD.org/httpd.8</a><br />
-<a class='textlink' href='https://man.OpenBSD.org/relayd.8'>https://man.OpenBSD.org/relayd.8</a><br />
-<br />
-<span>For example, the master is responsible for the <span class='inlinecode'>https://www.foo.zone</span> and <span class='inlinecode'>https://foo.zone</span> hosts, whereas the standby can be reached via <span class='inlinecode'>https://standby.foo.zone</span> (port 80 for plain HTTP works as well). The same principle is followed with all the other hosts, e.g. <span class='inlinecode'>irregular.ninja</span>, <span class='inlinecode'>paul.buetow.org</span> and so on. The same applies to my Gemini capsules for <span class='inlinecode'>https://foo.zone</span>, <span class='inlinecode'>https://standby.foo.zone</span>, <span class='inlinecode'>https://paul.buetow.org</span> and <span class='inlinecode'>https://standby.paul.buetow.org</span>.</span><br />
-<br />
-<span>On DNS failover, master and standby swap roles without config changes other than the DNS entries. That&#39;s KISS (keep it simple and stupid)!</span><br />
-<br />
-<h3 style='display: inline' id='let-s-encrypt-tls-certificates'>Let&#39;s encrypt TLS certificates</h3><br />
-<br />
-<span>All my hosts use TLS certificates from Let&#39;s Encrypt. The ACME automation for requesting and keeping the certificates valid (up to date) requires that the host requesting a certificate from Let&#39;s Encrypt is also the host using that certificate.</span><br />
-<br />
-<span>If the master always serves <span class='inlinecode'>foo.zone</span> and the standby always <span class='inlinecode'>standby.foo.zone</span>, then there would be a problem after the failover, as the new master wouldn&#39;t have a valid certificate for <span class='inlinecode'>foo.zone</span> and the new standby wouldn&#39;t have a valid certificate for <span class='inlinecode'>standby.foo.zone</span> which would lead to TLS errors on the clients.</span><br />
-<br />
-<span>As a solution, the CRON job responsible for the DNS failover also checks for the current week number of the year so that:</span><br />
-<br />
-<ul>
-<li>In an odd week number, the first server is the default master</li>
-<li>In an even week number, the second server is the default master.</li>
-</ul><br />
-<span>Which translates to:</span><br />
-<br />
-<!-- Generator: GNU source-highlight 3.1.9
-by Lorenzo Bettini
-http://www.lorenzobettini.it
-http://www.gnu.org/software/src-highlite -->
-<pre><i><font color="silver"># Weekly auto-failover for Let's Encrypt automation</font></i>
-<b><u><font color="#000000">local</font></u></b> -i -r week_of_the_year=$(date +%U)
-<b><u><font color="#000000">if</font></u></b> [ $(( week_of_the_year % <font color="#000000">2</font> )) -eq <font color="#000000">0</font> ]; <b><u><font color="#000000">then</font></u></b>
- <b><u><font color="#000000">local</font></u></b> tmp=$master
- master=$standby
- standby=$tmp
-<b><u><font color="#000000">fi</font></u></b>
-</pre>
-<br />
-<span>This way, a DNS failover is performed weekly so that the ACME automation can update the Let&#39;s Encrypt certificates (for master and standby) before they expire on each VM.</span><br />
-<br />
-<span>The ACME automation is yet another daily CRON script <span class='inlinecode'>/usr/local/bin/acme.sh</span>. It iterates over all of my Let&#39;s Encrypt hosts, checks whether they resolve to the same IP address as the current VM, and only then invokes the ACME client to request or renew the TLS certificates. So, there are always correct requests made to Let&#39;s Encrypt. </span><br />
-<br />
-<span>Let&#39;s encrypt certificates usually expire after 3 months, so a weekly failover of my VMs is plenty.</span><br />
-<br />
-<a class='textlink' href='https://codeberg.org/snonux/conf/src/branch/master/frontends/scripts/acme.sh.tpl'><span class='inlinecode'>acme.sh.tpl</span> - Rex template for the <span class='inlinecode'>acme.sh</span> script of mine.</a><br />
-<a class='textlink' href='https://man.OpenBSD.org/acme-client.1'>https://man.OpenBSD.org/acme-client.1</a><br />
-<a class='textlink' href='./2022-07-30-lets-encrypt-with-openbsd-and-rex.html'>Let&#39;s Encrypt with OpenBSD and Rex</a><br />
-<br />
-<h3 style='display: inline' id='monitoring'>Monitoring</h3><br />
-<br />
-<span>CRON is sending me an E-Mail whenever a failover is performed (or whenever a failover failed). Furthermore, I am monitoring my DNS servers and hosts through Gogios, the monitoring system I have developed. </span><br />
-<br />
-<a class='textlink' href='https://codeberg.org/snonux/gogios'>https://codeberg.org/snonux/gogios</a><br />
-<a class='textlink' href='./2023-06-01-kiss-server-monitoring-with-gogios.html'>KISS server monitoring with Gogios</a><br />
-<br />
-<span>Gogios, as I developed it by myself, isn&#39;t part of the OpenBSD base system. </span><br />
-<br />
-<h3 style='display: inline' id='rex-automation'>Rex automation</h3><br />
-<br />
-<span>I use Rexify, a friendly configuration management system that allows automatic deployment and configuration.</span><br />
-<br />
-<a class='textlink' href='https://www.rexify.org'>https://www.rexify.org</a><br />
-<a class='textlink' href='https://codeberg.org/snonux/conf/src/branch/master/frontends'>codeberg.org/snonux/rexfiles/frontends</a><br />
-<br />
-<span>Rex isn&#39;t part of the OpenBSD base system, but I didn&#39;t need to install any external software on OpenBSD either as Rex is invoked from my Laptop!</span><br />
-<br />
-<h2 style='display: inline' id='more-ha'>More HA</h2><br />
-<br />
-<span>Other high-available services running on my OpenBSD VMs are my MTAs for mail forwarding (OpenSMTPD - also part of the OpenBSD base system) and the authoritative DNS servers (<span class='inlinecode'>nsd</span>) for all my domains. No particular HA setup is required, though, as the protocols (SMTP and DNS) already take care of the failover to the next available host! </span><br />
-<br />
-<a class='textlink' href='https://www.OpenSMTPD.org/'>https://www.OpenSMTPD.org/</a><br />
-<br />
-<span>As a password manager, I use <span class='inlinecode'>geheim</span>, a command-line tool I wrote in Ruby with encrypted files in a git repository (I even have it installed in Termux on my Phone). For HA reasons, I simply updated the client code so that it always synchronises the database with both servers when I run the <span class='inlinecode'>sync</span> command there. </span><br />
-<br />
-<a class='textlink' href='https://codeberg.org/snonux/geheim'>https://codeberg.org/snonux/geheim</a><br />
-<br />
-<span>E-Mail your comments to <span class='inlinecode'>paul@nospam.buetow.org</span> :-)</span><br />
-<br />
-<span>Other *BSD and KISS related posts are:</span><br />
-<br />
-<a class='textlink' href='./2025-12-07-f3s-kubernetes-with-freebsd-part-8.html'>2025-12-07 f3s: Kubernetes with FreeBSD - Part 8: Observability</a><br />
-<a class='textlink' href='./2025-10-02-f3s-kubernetes-with-freebsd-part-7.html'>2025-10-02 f3s: Kubernetes with FreeBSD - Part 7: k3s and first pod deployments</a><br />
-<a class='textlink' href='./2025-07-14-f3s-kubernetes-with-freebsd-part-6.html'>2025-07-14 f3s: Kubernetes with FreeBSD - Part 6: Storage</a><br />
-<a class='textlink' href='./2025-05-11-f3s-kubernetes-with-freebsd-part-5.html'>2025-05-11 f3s: Kubernetes with FreeBSD - Part 5: WireGuard mesh network</a><br />
-<a class='textlink' href='./2025-04-05-f3s-kubernetes-with-freebsd-part-4.html'>2025-04-05 f3s: Kubernetes with FreeBSD - Part 4: Rocky Linux Bhyve VMs</a><br />
-<a class='textlink' href='./2025-02-01-f3s-kubernetes-with-freebsd-part-3.html'>2025-02-01 f3s: Kubernetes with FreeBSD - Part 3: Protecting from power cuts</a><br />
-<a class='textlink' href='./2024-12-03-f3s-kubernetes-with-freebsd-part-2.html'>2024-12-03 f3s: Kubernetes with FreeBSD - Part 2: Hardware and base installation</a><br />
-<a class='textlink' href='./2024-11-17-f3s-kubernetes-with-freebsd-part-1.html'>2024-11-17 f3s: Kubernetes with FreeBSD - Part 1: Setting the stage</a><br />
-<a class='textlink' href='./2024-04-01-KISS-high-availability-with-OpenBSD.html'>2024-04-01 KISS high-availability with OpenBSD (You are currently reading this)</a><br />
-<a class='textlink' href='./2024-01-13-one-reason-why-i-love-openbsd.html'>2024-01-13 One reason why I love OpenBSD</a><br />
-<a class='textlink' href='./2023-10-29-kiss-static-web-photo-albums-with-photoalbum.sh.html'>2023-10-29 KISS static web photo albums with <span class='inlinecode'>photoalbum.sh</span></a><br />
-<a class='textlink' href='./2023-06-01-kiss-server-monitoring-with-gogios.html'>2023-06-01 KISS server monitoring with Gogios</a><br />
-<a class='textlink' href='./2022-10-30-installing-dtail-on-openbsd.html'>2022-10-30 Installing DTail on OpenBSD</a><br />
-<a class='textlink' href='./2022-07-30-lets-encrypt-with-openbsd-and-rex.html'>2022-07-30 Let&#39;s Encrypt with OpenBSD and Rex</a><br />
-<a class='textlink' href='./2016-04-09-jails-and-zfs-on-freebsd-with-puppet.html'>2016-04-09 Jails and ZFS with Puppet on FreeBSD</a><br />
-<br />
-<a class='textlink' href='../'>Back to the main site</a><br />
- </div>
- </content>
- </entry>
- <entry>
- <title>A fine Fyne Android app for quickly logging ideas programmed in Go</title>
- <link href="https://foo.zone/gemfeed/2024-03-03-a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang.html" />
- <id>https://foo.zone/gemfeed/2024-03-03-a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang.html</id>
- <updated>2024-03-03T00:07:21+02:00</updated>
- <author>
- <name>Paul Buetow aka snonux</name>
- <email>paul@dev.buetow.org</email>
- </author>
- <summary>I am an ideas person. I find myself frequently somewhere on the streets with an idea in my head but no paper journal noting it down. </summary>
- <content type="xhtml">
- <div xmlns="http://www.w3.org/1999/xhtml">
- <h1 style='display: inline' id='a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-go'>A fine Fyne Android app for quickly logging ideas programmed in Go</h1><br />
-<br />
-<span class='quote'>Published at 2024-03-03T00:07:21+02:00</span><br />
-<br />
-<span>I am an ideas person. I find myself frequently somewhere on the streets with an idea in my head but no paper journal noting it down. </span><br />
-<br />
-<span>I have tried many note apps for my Android (I use GrapheneOS) phone. Most of them either don&#39;t do what I want, are proprietary software, require Google Play services (I have the main profile on my phone de-googled) or are too bloated. I was never into mobile app development, as I&#39;m not too fond of the complexity of the developer toolchains. I don&#39;t want to use Android Studio (as a NeoVim user), and I don&#39;t want to use Java or Kotlin. I want to use a language I know (and like) for mobile app development. Go would be one of those languages.</span><br />
-<br />
-<a href='a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang/logo-small.png'><img alt='Quick logger Logo' title='Quick logger Logo' src='a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang/logo-small.png' /></a><br />
-<br />
-<h2 style='display: inline' id='table-of-contents'>Table of Contents</h2><br />
-<br />
-<ul>
-<li><a href='#a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-go'>A fine Fyne Android app for quickly logging ideas programmed in Go</a></li>
-<li>⇢ <a href='#enter-quick-logger'>Enter Quick logger</a></li>
-<li>⇢ <a href='#all-easy-peasy'>All easy-peasy?</a></li>
-</ul><br />
-<h2 style='display: inline' id='enter-quick-logger'>Enter Quick logger</h2><br />
-<br />
-<span>Enter Quick logger – a compact GUI Android (well, cross-platform due to Fyne) app I&#39;ve crafted using Go and the nifty Fyne framework. With Fyne, the app can be compiled easily into an Android APK. As of this writing, this app&#39;s whole Go source code is only 75 lines short!! This little tool is designed for spontaneous moments, allowing me to quickly log my thoughts as plain text files on my Android phone. There are no fancy file formats. Just plain text!</span><br />
-<br />
-<a class='textlink' href='https://codeberg.org/snonux/quicklogger'>https://codeberg.org/snonux/quicklogger</a><br />
-<a class='textlink' href='https://fyne.io'>https://fyne.io</a><br />
-<a class='textlink' href='https://go.dev'>https://go.dev</a><br />
-<br />
-<span>There&#39;s no need to navigate complex menus or deal with sync issues. I jot down my Idea, and Quick logger saves it to a plain text file in a designated local folder on my phone. There is one text file per note (timestamp in the file name). Once logged, the file can&#39;t be edited anymore (it keeps it simple). If I want to correct or change a note, I simply write a new one. My notes are always small (usually one short sentence each), so there isn&#39;t the need for an edit functionality. I can edit them later on my actual computer if I want to.</span><br />
-<br />
-<span>With Syncthing, the note files are then synchronised to my home computer to my <span class='inlinecode'>~/Notes</span> directory. From there, a small glue Raku script adds them to my Taskwarrior DB so that I can process them later (e.g. take action on that one Idea I had). That then will delete the original note files from my computer and also (through Syncthing) from my phone.</span><br />
-<br />
-<a class='textlink' href='https://syncthing.net'>https://syncthing.net</a><br />
-<a class='textlink' href='https://raku.org'>https://raku.org</a><br />
-<a class='textlink' href='https://taskwarrior.org'>https://taskwarrior.org</a><br />
-<br />
-<span>Quick logger&#39;s user interface is as minimal as it gets. When I launch Quick logger, I&#39;m greeted with a simple window where I can type plain text. Hit the "Log text" button, and voilà – the input is timestamped and saved as a file in my chosen directory. If I need to change the directory, the "Preferences" button brings up a window where I can set the notes folder and get back to logging.</span><br />
-<br />
-<span>For the code-savvy folks out there, Quick logger is a neat example of what you can achieve with Go and Fyne. It&#39;s a testament to building functional, cross-platform apps without getting bogged down in the nitty-gritty of platform-specific details. Thanks to Fyne, I am pleased with how easy it is to make mobile Android apps in Go.</span><br />
-<br />
-<a href='a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang/screenshot-android.png'><img alt='Quick logger running on Android' title='Quick logger running on Android' src='a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang/screenshot-android.png' /></a><br />
-<br />
-<span>My Android apps will never be polished, but they will get the job done, and this is precisely how I want them to be. Minimalistic but functional. I could spend more time polishing Quick logger, but my Quick logger app then may be the same as any other notes app out there (complicated or bloated).</span><br />
-<br />
-<h2 style='display: inline' id='all-easy-peasy'>All easy-peasy?</h2><br />
-<br />
-<span class='quote'>Updated 2025-05-15: When using <span class='inlinecode'>fyne-cross android</span> everything works now! I don&#39;t have to perform any of the work-arounds listed below anymore!</span><br />
-<br />
-<span>I did have some issues with the app logo for Android, though. Android always showed the default app icon and not my custom icon whenever I used a custom <span class='inlinecode'>AndroidManifest.xml</span> for custom app storage permissions. Without a custom <span class='inlinecode'>AndroidAmnifest.xml</span> the app icon would be displayed under Android, but then the app would not have the <span class='inlinecode'>MANAGE_EXTERNAL_STORAGE</span> permission, which is required for Quick logger to write to a custom directory. I found a workaround, which I commented on here at Github:</span><br />
-<br />
-<a class='textlink' href='https://github.com/fyne-io/fyne/issues/3077#issuecomment-1912697360'>https://github.com/fyne-io/fyne/issues/3077#issuecomment-1912697360</a><br />
-<br />
-<span class='quote'>What worked however (app icon showing up) was to clone the fyne project, change the occurances of android.permission.INTERNET to android.permission.MANAGE_EXTERNAL_STORAGE (as these are all the changes I want in my custom android manifest) in the source tree, re-compile fyne. Now all works. I know, this is more of an hammer approach!</span><br />
-<br />
-<span>Hopefully, I won&#39;t need to use this workaround anymore. But for now, it is a fair tradeoff for what I am getting.</span><br />
-<br />
-<span>I hope this will inspire you to write your own small mobile apps in Go using the awesome Fyne framework! PS: The Quick logger logo was generated by ChatGPT.</span><br />
-<br />
-<span>E-Mail your comments to <span class='inlinecode'>paul@nospam.buetow.org</span> :-)</span><br />
-<br />
-<span>Other Go related posts are:</span><br />
-<br />
-<a class='textlink' href='./2024-03-03-a-fine-fyne-android-app-for-quickly-logging-ideas-programmed-in-golang.html'>2024-03-03 A fine Fyne Android app for quickly logging ideas programmed in Go (You are currently reading this)</a><br />
-<br />
-<a class='textlink' href='../'>Back to the main site</a><br />
- </div>
- </content>
- </entry>
</feed>
diff --git a/gemfeed/index.html b/gemfeed/index.html
index a6a508f4..cc353f08 100644
--- a/gemfeed/index.html
+++ b/gemfeed/index.html
@@ -15,6 +15,8 @@
<br />
<h2 style='display: inline' id='to-be-in-the-zone'>To be in the .zone!</h2><br />
<br />
+<a class='textlink' href='./2026-02-15-loadbars-resurrected-from-perl-to-go.html'>2026-02-15 - Loadbars resurrected: From Perl to Go after 15 years</a><br />
+<a class='textlink' href='./2026-02-14-til-meta-slash-commands-for-ai-workflows.html'>2026-02-14 - TIL: Meta slash-commands for reusable AI prompts and context</a><br />
<a class='textlink' href='./2026-02-14-meta-slash-commands-for-prompts-and-context.html'>2026-02-14 - Meta slash-commands to manage prompts and context for coding agents</a><br />
<a class='textlink' href='./2026-02-02-tmux-popup-editor-for-cursor-agent-prompts.html'>2026-02-02 - A tmux popup editor for Cursor Agent CLI prompts</a><br />
<a class='textlink' href='./2026-01-01-using-supernote-nomad-offline.html'>2026-01-01 - Using Supernote Nomad offline</a><br />
diff --git a/gemfeed/loadbars-resurrected-from-perl-to-go/loadbars.gif b/gemfeed/loadbars-resurrected-from-perl-to-go/loadbars.gif
new file mode 100644
index 00000000..b012e48b
--- /dev/null
+++ b/gemfeed/loadbars-resurrected-from-perl-to-go/loadbars.gif
Binary files differ