<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0">
    <channel>
      <title>Alexander Weld</title>
      <link>https://weldale.xyz</link>
      <description>Alexander Weld&#x27;s Homepage</description>
      <generator>Zola</generator>
      <language>en</language>
      <atom:link href="https://weldale.xyz/rss.xml" rel="self" type="application/rss+xml"/>
      <lastBuildDate>Tue, 10 Mar 2026 00:00:00 +0000</lastBuildDate>
      <item>
          <title>Ferrous Menu</title>
          <pubDate>Tue, 10 Mar 2026 00:00:00 +0000</pubDate>
          <author>aweld</author>
          <link>https://weldale.xyz/projects/fmenu/</link>
          <guid>https://weldale.xyz/projects/fmenu/</guid>
          <description xml:base="https://weldale.xyz/projects/fmenu/">&lt;p&gt;&lt;strong&gt;Gitlab&lt;&#x2F;strong&gt;: &lt;a rel=&quot;external&quot; href=&quot;https:&#x2F;&#x2F;gitlab.com&#x2F;xicalango&#x2F;fmenu&quot;&gt;https:&#x2F;&#x2F;gitlab.com&#x2F;xicalango&#x2F;fmenu&lt;&#x2F;a&gt;&lt;&#x2F;p&gt;
&lt;p&gt;&lt;strong&gt;Crate&lt;&#x2F;strong&gt;: &lt;a rel=&quot;external&quot; href=&quot;https:&#x2F;&#x2F;crates.io&#x2F;crates&#x2F;ferrous-menu&quot;&gt;https:&#x2F;&#x2F;crates.io&#x2F;crates&#x2F;ferrous-menu&lt;&#x2F;a&gt;&lt;&#x2F;p&gt;
&lt;h1 id=&quot;ferrous-menu-fmenu&quot;&gt;Ferrous Menu (fmenu)&lt;&#x2F;h1&gt;
&lt;p&gt;Ferrous Menu (or &lt;code&gt;fmenu&lt;&#x2F;code&gt; in short) is a minmal GUI for choice selection, similar to &lt;code&gt;dmenu&lt;&#x2F;code&gt; or &lt;code&gt;rofi&lt;&#x2F;code&gt;, written in rust using FLTK.&lt;&#x2F;p&gt;
&lt;h1 id=&quot;usage&quot;&gt;Usage&lt;&#x2F;h1&gt;
&lt;h2 id=&quot;basic-usage&quot;&gt;Basic Usage&lt;&#x2F;h2&gt;
&lt;pre class=&quot;giallo&quot; style=&quot;color: #CDD6F4; background-color: #1E1E2E;&quot;&gt;&lt;code data-lang=&quot;shellscript&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #89B4FA;font-style: italic;&quot;&gt;fmenu&lt;&#x2F;span&gt;&lt;span style=&quot;color: #A6E3A1;&quot;&gt; -o option1 -o option2 -o option3&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;
&lt;p&gt;This will show a window for selecting between the three options &lt;code&gt;option1&lt;&#x2F;code&gt;, &lt;code&gt;option2&lt;&#x2F;code&gt;, &lt;code&gt;option3&lt;&#x2F;code&gt;:&lt;&#x2F;p&gt;
&lt;p&gt;&lt;img src=&quot;&#x2F;img&#x2F;projects&#x2F;fmenu.png&quot; alt=&quot;fmenu screenshot&quot; &#x2F;&gt;&lt;&#x2F;p&gt;
&lt;p&gt;The selected option will be printed to stdout once the user presses &lt;code&gt;Enter&lt;&#x2F;code&gt;.&lt;&#x2F;p&gt;
&lt;p&gt;If no selection was made (for example because the user pressed &lt;code&gt;ESC&lt;&#x2F;code&gt; to close the window), the application will exit with error code 75.&lt;&#x2F;p&gt;
&lt;h2 id=&quot;reading-options-from-stdin&quot;&gt;Reading options from stdin&lt;&#x2F;h2&gt;
&lt;p&gt;Instead of giving the options via command-line flags you can also provide them via stdin:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo&quot; style=&quot;color: #CDD6F4; background-color: #1E1E2E;&quot;&gt;&lt;code data-lang=&quot;shellscript&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #89B4FA;font-style: italic;&quot;&gt;ls&lt;&#x2F;span&gt;&lt;span style=&quot;color: #94E2D5;&quot;&gt; |&lt;&#x2F;span&gt;&lt;span style=&quot;color: #89B4FA;font-style: italic;&quot;&gt; fmenu&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;
&lt;p&gt;This will show all files in the current directory for selection.&lt;&#x2F;p&gt;
&lt;h2 id=&quot;filtering&quot;&gt;Filtering&lt;&#x2F;h2&gt;
&lt;p&gt;You can filter the options by typing in a string that should appear anywhere in the desired option. If the string appears anywhere in the list of options it will be shown.&lt;&#x2F;p&gt;
&lt;h2 id=&quot;configuration&quot;&gt;Configuration&lt;&#x2F;h2&gt;
&lt;p&gt;Fmenu can be configured through a configuration file. The default location for the configuration file is &lt;code&gt;$XDG_CONFIG_DIR&#x2F;fmenu.rc&lt;&#x2F;code&gt; and can be overwritten with the &lt;code&gt;-c &amp;lt;configfile&amp;gt;&lt;&#x2F;code&gt; argument.&lt;&#x2F;p&gt;
&lt;p&gt;Here&#x27;s an example configuration file showing all options:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo&quot; style=&quot;color: #CDD6F4; background-color: #1E1E2E;&quot;&gt;&lt;code data-lang=&quot;toml&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;[&lt;&#x2F;span&gt;&lt;span&gt;window&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;]&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;width: 800            &lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;font-style: italic;&quot;&gt;# width of the window [default: 800]&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;height: 600           &lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;font-style: italic;&quot;&gt;# height of the window [default: 600]&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;positioning: center   &lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;font-style: italic;&quot;&gt;# positioning strategy of the window [default: center]&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;[&lt;&#x2F;span&gt;&lt;span&gt;theme&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;]&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span&gt;theme&lt;&#x2F;span&gt;&lt;span style=&quot;color: #94E2D5;&quot;&gt; =&lt;&#x2F;span&gt;&lt;span style=&quot;color: #A6E3A1;&quot;&gt; &amp;quot;black&amp;quot;&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;font-style: italic;&quot;&gt;       # FLTK theme [optional]&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;&lt;h3 id=&quot;themes&quot;&gt;Themes&lt;&#x2F;h3&gt;
&lt;p&gt;Fmenu uses the &lt;a rel=&quot;external&quot; href=&quot;https:&#x2F;&#x2F;github.com&#x2F;fltk-rs&#x2F;fltk-theme&quot;&gt;fltk-theme&lt;&#x2F;a&gt; to apply themes. Hence the list of available themes is:&lt;&#x2F;p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;Black&lt;&#x2F;code&gt;&lt;&#x2F;li&gt;
&lt;li&gt;&lt;code&gt;Dark&lt;&#x2F;code&gt;&lt;&#x2F;li&gt;
&lt;li&gt;&lt;code&gt;Grey&lt;&#x2F;code&gt;&lt;&#x2F;li&gt;
&lt;li&gt;&lt;code&gt;Shake&lt;&#x2F;code&gt;&lt;&#x2F;li&gt;
&lt;li&gt;&lt;code&gt;Tan&lt;&#x2F;code&gt;&lt;&#x2F;li&gt;
&lt;&#x2F;ul&gt;
&lt;h1 id=&quot;motivation&quot;&gt;Motivation&lt;&#x2F;h1&gt;
&lt;p&gt;I think I started this project because I wanted to run &lt;a rel=&quot;external&quot; href=&quot;https:&#x2F;&#x2F;git.zx2c4.com&#x2F;password-store&#x2F;tree&#x2F;contrib&#x2F;dmenu&#x2F;passmenu&quot;&gt;passmenu&lt;&#x2F;a&gt; on a MacBook, but couldn&#x27;t get &lt;code&gt;dmenu&lt;&#x2F;code&gt; (or a replacement) to work like I wanted it to work.&lt;&#x2F;p&gt;
&lt;p&gt;From a previous project I knew that FLTK applications compile and run somewhat easily on MacOS, so and I was already somewhat familiar how to program FLTK apps in rust, so I wrote this small replacement.&lt;&#x2F;p&gt;
&lt;p&gt;As a result, &lt;code&gt;fmenu&lt;&#x2F;code&gt; has been tested thoroughly as a replacement for &lt;code&gt;dmenu&lt;&#x2F;code&gt; in passmenu.&lt;&#x2F;p&gt;
&lt;h1 id=&quot;implementation-details&quot;&gt;Implementation details&lt;&#x2F;h1&gt;
&lt;p&gt;Since the project is so small there isn&#x27;t too much to say about it&#x27;s implementation.&lt;&#x2F;p&gt;
&lt;p&gt;The only thing to highlight is probably how managing the GUI state is done via message passing (which is also a pretty standard way of handling GUIs).
The nice thing about this is that the functionality is a bit more decoupled from the GUI.&lt;&#x2F;p&gt;
&lt;p&gt;There are 5 defined messages:&lt;&#x2F;p&gt;
&lt;pre class=&quot;giallo&quot; style=&quot;color: #CDD6F4; background-color: #1E1E2E;&quot;&gt;&lt;code data-lang=&quot;rust&quot;&gt;&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #CBA6F7;&quot;&gt;enum&lt;&#x2F;span&gt;&lt;span style=&quot;color: #F9E2AF;font-style: italic;&quot;&gt; UiMessage&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt; {&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #F9E2AF;font-style: italic;&quot;&gt;    MoveDown&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #F9E2AF;font-style: italic;&quot;&gt;    MoveUp&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #F9E2AF;font-style: italic;&quot;&gt;    Select&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;,&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #89B4FA;font-style: italic;&quot;&gt;    SelectValue&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;(&lt;&#x2F;span&gt;&lt;span style=&quot;color: #F9E2AF;font-style: italic;&quot;&gt;String&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;),&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #89B4FA;font-style: italic;&quot;&gt;    Filter&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;(&lt;&#x2F;span&gt;&lt;span style=&quot;color: #F9E2AF;font-style: italic;&quot;&gt;String&lt;&#x2F;span&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;),&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;
&lt;span class=&quot;giallo-l&quot;&gt;&lt;span style=&quot;color: #9399B2;&quot;&gt;}&lt;&#x2F;span&gt;&lt;&#x2F;span&gt;&lt;&#x2F;code&gt;&lt;&#x2F;pre&gt;
&lt;p&gt;Two of the options (&lt;code&gt;MoveDown&lt;&#x2F;code&gt;, &lt;code&gt;MoveUp&lt;&#x2F;code&gt;) are for moving the selection, &lt;code&gt;Select&lt;&#x2F;code&gt; is for confirming the current selection, &lt;code&gt;SelectValue&lt;&#x2F;code&gt; is for the case a user clicked on an option, and &lt;code&gt;Filter&lt;&#x2F;code&gt; is for filtering the selections.&lt;&#x2F;p&gt;
&lt;p&gt;Each action in the UI, e.g. pressing the up&#x2F;down arrow key, pressing enter, typing a filter, or clicking on an entry will emit one of these (domain specific) messages, which then will be handled by a simple main loop.
The loop with listen for incoming UI messages and update the state based on these messages.&lt;&#x2F;p&gt;
&lt;p&gt;This makes the logic very easy to understand and predictable.&lt;&#x2F;p&gt;
</description>
      </item>
      <item>
          <title>Sqlitepipe (my first published crate)</title>
          <pubDate>Fri, 06 Mar 2026 00:00:00 +0000</pubDate>
          <author>aweld</author>
          <link>https://weldale.xyz/blog/sqlitepipe/</link>
          <guid>https://weldale.xyz/blog/sqlitepipe/</guid>
          <description xml:base="https://weldale.xyz/blog/sqlitepipe/">&lt;p&gt;Ever wanted to pipe the output of arbitrary commands into a sqlite database?
Now you can do that using my first published crate: &lt;a rel=&quot;external&quot; href=&quot;https:&#x2F;&#x2F;crates.io&#x2F;crates&#x2F;sqlitepipe&quot;&gt;sqlitepipe&lt;&#x2F;a&gt;&lt;&#x2F;p&gt;
&lt;p&gt;You can read more about it here: &lt;a href=&quot;&#x2F;projects&#x2F;sqlitepipe&quot;&gt;sqlitepipe&lt;&#x2F;a&gt;&lt;&#x2F;p&gt;
&lt;p&gt;I hope I manage to publish more of the small command line tools I wrote over the last years and share them, hoping that other people find them as useful as I do.&lt;&#x2F;p&gt;
</description>
      </item>
      <item>
          <title>Zola website</title>
          <pubDate>Sun, 11 Jan 2026 00:00:00 +0000</pubDate>
          <author>aweld</author>
          <link>https://weldale.xyz/blog/zola/</link>
          <guid>https://weldale.xyz/blog/zola/</guid>
          <description xml:base="https://weldale.xyz/blog/zola/">&lt;p&gt;I&#x27;m finally moving away from using &lt;a rel=&quot;external&quot; href=&quot;https:&#x2F;&#x2F;dynalon.github.io&#x2F;mdwiki&#x2F;&quot;&gt;mdwiki&lt;&#x2F;a&gt; for my personal website and ended up with the static site generator &lt;a rel=&quot;external&quot; href=&quot;https:&#x2F;&#x2F;www.getzola.org&#x2F;&quot;&gt;Zola&lt;&#x2F;a&gt;.&lt;&#x2F;p&gt;
&lt;p&gt;Main motivation was that &lt;code&gt;mdwiki&lt;&#x2F;code&gt; always needs javascript enabled, while the Zola template i&#x27;m using (&lt;a rel=&quot;external&quot; href=&quot;https:&#x2F;&#x2F;salif.github.io&#x2F;linkita&#x2F;&quot;&gt;linkita&lt;&#x2F;a&gt;) even renders with javascript disabled and can even be viewed using your favorite text based browser (which is obviously very important in the year 2026).&lt;&#x2F;p&gt;
&lt;p&gt;Maybe i&#x27;m now even motivated to blog and write about my projects more. For example why don&#x27;t you check out &lt;a href=&quot;&#x2F;projects&#x2F;ed&quot;&gt;ed.awk&lt;&#x2F;a&gt; my &lt;code&gt;ed&lt;&#x2F;code&gt; implementation in AWK.&lt;&#x2F;p&gt;
</description>
      </item>
    </channel>
</rss>
