This commit is contained in:
ryfrd 2026-03-18 20:32:25 +00:00
parent 6623ee03f6
commit 44c8324063
120 changed files with 22842 additions and 4673 deletions

View file

@ -1,86 +1,39 @@
<!doctype html>
<html lang="en"><head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="shortcut icon" href="https://nonsense.dymc.win/favicon.ico">
<link rel="alternate" type="application/rss+xml" href="https://nonsense.dymc.win/categories/index.xml" title="James' Blog">
<link id="stylesheet" rel="stylesheet" href="/css/light.css">
<html lang="en"><head><script src="/livereload.js?mindelay=10&amp;v=2&amp;port=1313&amp;path=livereload" data-no-instant defer></script>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="canonical" href="http://localhost:1313/categories/" />
<title>Categories - James&#39; Blog</title>
<link rel="canonical" href="https://nonsense.dymc.win/categories/" />
<title>Categories</title>
<link rel="alternate" type="application/rss+xml" href="http://localhost:1313/categories/index.xml" title="James' Blog">
<link rel="stylesheet" href="/css/style.css">
<script>
document.documentElement.setAttribute('data-theme', 'dark');
</script>
</head>
<body><header id="banner">
<nav class="navbar">
<body><header class="site-header">
<nav>
<a href="http://localhost:1313/" class="home">~</a>
<div class="nav-links">
<a href="https://nonsense.dymc.win/" class="home">🏠</a>
<a
href="/info/"
title="👋"
>👋</a
><a
href="/search/"
title="🔎"
>🔎</a
>
<button id="toggle-button" class="toggle-button" onclick="toggleTheme()">🌚</button>
<a href="/search">/</a>
</div>
</nav>
</header>
<main id="content">
<a href="/wuthering-heights-2026/">Wuthering Heights (2026)</a>
<a href="/handy-script-for-a-more-zen-twitch-experience/">Handy script for a more zen twitch experience</a>
<a href="/over-engineered-nixos-blog-deployment-setup/">Over-engineered (?) nixos blog deployment setup</a>
<a href="/so-you-want-to-write-a-neovim-plugin-with-lua/">So you want to write a neovim plugin with lua</a>
<a href="/making-nix-colors-talk-to-neovim/">Making nix-colors talk to neovim</a>
<a href="/vanilla-javascript-theme-toggle-for-simpletons/">Vanilla javascript theme toggle for simpletons</a>
<a href="/tailscale-caddy-and-nixos-containers/">Tailscale, caddy, and nixos containers</a>
<a href="/learning-about-qtile-widgets-with-cricket/">Learning about qtile widgets with cricket</a>
<a href="/achieve-peak-rice-with-nix-colors/">Achieve peak rice with nix-colors</a>
<a href="/translating-docker-to-nix/">Translating docker to nix?!</a>
<a href="/simple-nixos-config-for-vps-static-site/">Simple nixos config for vps static site</a>
<a href="/python-podcast-scripting/">Python podcast scripting</a>
<a href="/bread-dough-for-lazy-boys/">Bread dough for lazy boys</a>
<a href="/multi-user-qtile-fiddling/">Multi user qtile fiddling</a>
<a href="/teeny-tiny-bash-fetch-script/">Teeny tiny bash fetch script</a>
<a href="/get-the-thoughts-out-of-your-head-and-into-a-digital-format-with-this-python-journalling-script/">Get the thoughts out of your head and into a digital format with this python journalling script</a>
<a href="/lowkey-emacs-setup-bits-and-bobs/">Lowkey emacs setup bits and bobs</a>
<a href="/the-search-for-en-passant-checkmates-2-electric-boogaloo/">The search for en passant checkmates 2: Electric Boogaloo</a>
<a href="/the-search-for-en-passant-checkmates/">The search for en passant checkmates</a>
<a href="/declarative-firefox-config-with-home-manager-on-nixos/">Declarative firefox config with home-manager on nixos</a>
<a href="/upgrade-your-qtile-setup-with-a-cute-dropdown-terminal/">Upgrade your qtile setup with a cute dropdown terminal</a>
<a href="/rudimentary-local-scrobbling-with-bash/">Rudimentary local scrobbling with bash</a>
</main>
<footer id="footer">
<small>
made with <a href="https://gohugo.io">hugo</a>
</small>
<main id="content">
<h1>Tags</h1>
<ul class="post-list">
<script src="/js/search.js"></script>
<script src="/js/toggle.js"></script>
</ul>
</main><footer class="site-footer">
<small>
<a href="/index.xml">RSS</a>
·
<a href="https://gohugo.io">Hugo</a>
</small>
<script src="/js/script.js"></script>
</footer>
</body>
</body>
</html>

View file

@ -2,21 +2,99 @@
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>Categories on James&#39; Blog</title>
<link>https://nonsense.dymc.win/categories/</link>
<link>http://localhost:1313/categories/</link>
<description>Recent content in Categories on James&#39; Blog</description>
<generator>Hugo -- gohugo.io</generator>
<language>en-GB</language>
<atom:link href="https://nonsense.dymc.win/categories/index.xml" rel="self" type="application/rss+xml" />
<atom:link href="http://localhost:1313/categories/index.xml" rel="self" type="application/rss+xml" />
<item>
<title>Backing up nixos state with restic</title>
<link>http://localhost:1313/backing-up-nixos-state-with-restic/</link>
<pubDate>Mon, 16 Feb 2026 00:00:00 +0000</pubDate>
<guid>http://localhost:1313/backing-up-nixos-state-with-restic/</guid>
<description>&lt;p&gt;I&amp;rsquo;m writing this so I can hopefully remember what I did in six months.&lt;/p&gt;
&lt;p&gt;As hard as you try to eliminate all state from your computing life with nixos, the fact remains that you can&amp;rsquo;t get rid of all of it.
For example, I run forgejo on my VPS.
I have my config which means I could set up a forgejo instance just how I like it if everything went to pot.
But that wouldn&amp;rsquo;t bring back any of the repos I had there previously.&lt;/p&gt;
&lt;p&gt;This is the method I cooked up for backing up some of those important bits and bob from my VPS.&lt;/p&gt;
&lt;h3 id=&#34;restic&#34;&gt;Restic&lt;/h3&gt;
&lt;p&gt;&lt;a href=&#34;https://restic.net/&#34;&gt;Restic&lt;/a&gt; is a project which facilitates the encrypted, deduplicated backing up of your data to SFTP, S3, and various other cloud providers.
My backup target is a hetzner storage box which is compatible with SFTP so that&amp;rsquo;s the route I chose.
After browsing the &lt;a href=&#34;https://search.nixos.org/options?channel=unstable&amp;amp;query=restic&#34;&gt;available nixos options&lt;/a&gt;, I came up with this little config.
It sets up a restic job to be run daily by root backing up some of &lt;code&gt;/var/lib&lt;/code&gt; over sftp to the hetzner storage box (I&amp;rsquo;ve put in placeholder values).&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-nix&#34; data-lang=&#34;nix&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;{&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;config&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;...&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;}:&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;services&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;restic&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;backups&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;hetzner-storage-box&amp;#34;&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;initialize&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;user&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;root&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;passwordFile&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;/etc/nixos/secrets/restic&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;paths&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;/var/lib/important&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;/var/lib/stuff&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;];&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;repository&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;sftp:user@storagebox:/payload&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;extraOptions&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;sftp.command=&amp;#39;ssh user@storagebox -i /root/.ssh/id_ed25519 -s sftp&amp;#39;&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;];&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;timerConfig&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;OnCalendar&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;daily&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;Persistent&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id=&#34;security-concerns&#34;&gt;Security concerns&lt;/h3&gt;
&lt;p&gt;The eagle-eyed among you will have noticed some GAPING security flaws in this setup.
Firstly, my root user needs passwordless ssh access to the storage box.
Secondly, the password used to encrypt the backup is sitting in plaintext on my server at &lt;code&gt;/etc/nixos/secrets/restic&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;The first issue seems a little tricky to solve.
As far as I know there&amp;rsquo;s no way round the passwordless detail if you want an automated backup.
It would be better to run the backup as a less privileged user that still has permissions to the stuff you want to backup.
I&amp;rsquo;m not sure how to do that though and the whole thing seemed sufficiently complicated alraedy for me.
I found something about it in the docs &lt;a href=&#34;https://restic.readthedocs.io/en/stable/080_examples.html#full-backup-without-root&#34;&gt;here&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The second issue is extremely solvable with something like &lt;a href=&#34;https://github.com/Mic92/sops-nix&#34;&gt;sops-nix&lt;/a&gt; which I really do intend to setup at some point I promise!&lt;/p&gt;
&lt;h3 id=&#34;bonus-notifications&#34;&gt;Bonus: notifications&lt;/h3&gt;
&lt;p&gt;Seeing as these backups are going to be chugging away in the background in the middle of the night, it would be useful to be notified if they went wrong.
The nixos service sets up a systemd service for the restic job.
We can piggyback off this one with another systemd service which runs when the restic service fails.
This new service simply curls my &lt;a href=&#34;https://ntfy.sh&#34;&gt;ntfy&lt;/a&gt; server with an uh oh pay attention message.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-nix&#34; data-lang=&#34;nix&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;systemd&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;services&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;restic-backups-vps-storage-box&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;wantedBy&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;multi-user.target&amp;#34;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;];&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;unitConfig&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;OnFailure&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;restic-backups-failure-notify.service&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;systemd&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;services&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;restic-backups-failure-notify&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;description&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Notify on restic backup failure&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;serviceConfig&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;Type&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;oneshot&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;ExecStart&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;si&#34;&gt;${&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;pkgs&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;curl&lt;/span&gt;&lt;span class=&#34;si&#34;&gt;}&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;/bin/curl -s -X POST https://ntfy.sh/restic-backups-topic &amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;o&#34;&gt;+&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;-d &amp;#39;Restic backup from VPS to storage box failed!&amp;#39; &amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;o&#34;&gt;+&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;-H &amp;#39;Title: Backup Failed&amp;#39; &amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;o&#34;&gt;+&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;-H &amp;#39;Priority: high&amp;#39; &amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;User&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;root&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Thanks for reading :)&lt;/p&gt;
</description>
</item>
<item>
<title>Wuthering Heights (2026)</title>
<link>https://nonsense.dymc.win/wuthering-heights-2026/</link>
<link>http://localhost:1313/wuthering-heights-2026/</link>
<pubDate>Fri, 13 Feb 2026 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/wuthering-heights-2026/</guid>
<guid>http://localhost:1313/wuthering-heights-2026/</guid>
<description>&lt;h3 id=&#34;things-i-enjoyed&#34;&gt;Things I enjoyed&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Though not particularly &amp;lsquo;dark skinned&amp;rsquo;, Jacob Elordi is well suited to the role of surly sweaty gigahunk.&lt;/li&gt;
@ -30,7 +108,7 @@ It felt like a set not something the characters actually inahbited.
Even when they were banging on the moors they didn&amp;rsquo;t seem to get muddy.
This was a problem for me.&lt;/li&gt;
&lt;li&gt;Fundamentally, once you got past the visual glitz and knowingly executed tropes it felt completely emotionally empty.
Given that it&amp;rsquo;s a film about the enduring power of passionate undying love this was also a major problem.&lt;/li&gt;
Given that this version seems to be about the enduring power of passionate undying love this was also a major problem.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;things-that-intrigued-me&#34;&gt;Things that intrigued me&lt;/h3&gt;
&lt;ul&gt;
@ -45,10 +123,10 @@ Given that it&amp;rsquo;s a film about the enduring power of passionate undying
<item>
<title>Handy script for a more zen twitch experience</title>
<link>https://nonsense.dymc.win/handy-script-for-a-more-zen-twitch-experience/</link>
<link>http://localhost:1313/handy-script-for-a-more-zen-twitch-experience/</link>
<pubDate>Wed, 13 Aug 2025 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/handy-script-for-a-more-zen-twitch-experience/</guid>
<guid>http://localhost:1313/handy-script-for-a-more-zen-twitch-experience/</guid>
<description>&lt;p&gt;I like to watch twitch streams.
Watching them in the browser at &lt;code&gt;twitch.tv&lt;/code&gt; is generally not an experience which sparks joy though.
I&amp;rsquo;m buffering.
@ -150,15 +228,15 @@ Here it is:&lt;/p&gt;
<item>
<title>Over-engineered (?) nixos blog deployment setup</title>
<link>https://nonsense.dymc.win/over-engineered-nixos-blog-deployment-setup/</link>
<link>http://localhost:1313/over-engineered-nixos-blog-deployment-setup/</link>
<pubDate>Mon, 11 Aug 2025 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/over-engineered-nixos-blog-deployment-setup/</guid>
<guid>http://localhost:1313/over-engineered-nixos-blog-deployment-setup/</guid>
<description>&lt;p&gt;As is traditional with people hosting their own blog I&amp;rsquo;m going to do a post detailing EXACTLY how I&amp;rsquo;m hosting my blog.
Down to the last dirty detail.
I have nothing better to talk about.&lt;/p&gt;
&lt;p&gt;Here is a diagram I edited to illustrate (credit to xkcd I think?).&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://nonsense.dymc.win/image/self-hosting.png&#34; alt=&#34;self-hosting&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://localhost:1313/image/self-hosting.png&#34; alt=&#34;self-hosting&#34;&gt;&lt;/p&gt;
&lt;p&gt;I host my site on a hetzner vps running nixos.
I also have a git repo where all the static files for my blog live.
I had previously been manually rsyncing the website up to my vps from my laptop.
@ -241,12 +319,23 @@ That&amp;rsquo;s the directory of the git repo that the website source lives.&lt
<item>
<title>adventures in running headscale on nixos</title>
<link>http://localhost:1313/adventures-in-running-headscale-on-nixos/</link>
<pubDate>Tue, 25 Jun 2024 00:00:00 +0000</pubDate>
<guid>http://localhost:1313/adventures-in-running-headscale-on-nixos/</guid>
<description></description>
</item>
<item>
<title>So you want to write a neovim plugin with lua</title>
<link>https://nonsense.dymc.win/so-you-want-to-write-a-neovim-plugin-with-lua/</link>
<link>http://localhost:1313/so-you-want-to-write-a-neovim-plugin-with-lua/</link>
<pubDate>Sat, 06 Apr 2024 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/so-you-want-to-write-a-neovim-plugin-with-lua/</guid>
<guid>http://localhost:1313/so-you-want-to-write-a-neovim-plugin-with-lua/</guid>
<description>&lt;p&gt;I&amp;rsquo;ve recently been messing around with writing neovim plugins.
When I initially got going I found it a little tricky to know how to get started.
There&amp;rsquo;s the &lt;a href=&#34;https://neovim.io/doc&#34;&gt;official neovim docs&lt;/a&gt; which are great; but in my beginner experience exhaustive to the point of slight impenetrability.
@ -318,12 +407,47 @@ As a little coda, this is how you can use your fancy new plugin using &lt;a href
<item>
<title>nginx reverse-proxy with SSL for services running on tailscale!</title>
<link>http://localhost:1313/nginx-reverse-proxy-with-ssl-for-services-running-on-tailscale/</link>
<pubDate>Tue, 12 Sep 2023 00:00:00 +0000</pubDate>
<guid>http://localhost:1313/nginx-reverse-proxy-with-ssl-for-services-running-on-tailscale/</guid>
<description>&lt;p&gt;So you&amp;rsquo;re running something on a server somewhere. For whatever reason you cant or don&amp;rsquo;t want to expose ports 80 and 443 to the outside world.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-nix&#34; data-lang=&#34;nix&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;services&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;jellyfin&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;enable&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;security&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;acme&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;acceptTerms&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;defaults&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;email&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;barry@email.com&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;dnsProvider&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;cloudflare&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;credentialsFile&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;/etc/credentials.env&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;services&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;nginx&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;enable&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;virtualHosts&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;example.com&amp;#34;&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;enableACME&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;acmeRoot&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;null&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;addSSL&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;locations&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;/&amp;#34;&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;{&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;proxyPass&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;http://127.0.0.1:8096&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;proxyWebsockets&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;no&#34;&gt;true&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;};&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
</item>
<item>
<title>Making nix-colors talk to neovim</title>
<link>https://nonsense.dymc.win/making-nix-colors-talk-to-neovim/</link>
<link>http://localhost:1313/making-nix-colors-talk-to-neovim/</link>
<pubDate>Fri, 18 Aug 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/making-nix-colors-talk-to-neovim/</guid>
<guid>http://localhost:1313/making-nix-colors-talk-to-neovim/</guid>
<description>&lt;p&gt;I recently started fiddling around with home-managerifying my neovim config.
After moving across most of my stuff I came across the problem of how to hook things up with with &lt;a href=&#34;https://github.com/misterio77/nix-colors&#34;&gt;nix-colors&lt;/a&gt; so that my neovim theme would follow color changes in home-manager.&lt;/p&gt;
&lt;p&gt;Luckily, I came across &lt;a href=&#34;https://github.com/echasnovski/mini.nvim/blob/main/readmes/mini-base16.md&#34;&gt;this&lt;/a&gt; handy little plugin from the lovely &lt;a href=&#34;https://github.com/echasnovski/mini.nvim&#34;&gt;mini.nvim&lt;/a&gt; suite of plugins which lets you create your own theme with your custom colors.&lt;/p&gt;
@ -373,10 +497,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Vanilla javascript theme toggle for simpletons</title>
<link>https://nonsense.dymc.win/vanilla-javascript-theme-toggle-for-simpletons/</link>
<link>http://localhost:1313/vanilla-javascript-theme-toggle-for-simpletons/</link>
<pubDate>Mon, 26 Jun 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/vanilla-javascript-theme-toggle-for-simpletons/</guid>
<guid>http://localhost:1313/vanilla-javascript-theme-toggle-for-simpletons/</guid>
<description>&lt;p&gt;Sometimes when I&amp;rsquo;m trawling the internet and happen upon a particularly nice looking website, I develop css and javascript FOMO. The thing I&amp;rsquo;ve been lusting after above all else is one of those fancy little dark theme toggle buttons. As you can probably tell from the website you&amp;rsquo;re looking at my web dev skills are limited. As a result of this I had assumed such niceties were out of reach.&lt;/p&gt;
&lt;p&gt;Last week though I decided it was time for this to change! I would do a teeny bit of javascript. I could have nice things. This is a rundown of the very simple implementation I came up with.&lt;/p&gt;
&lt;h3 id=&#34;html&#34;&gt;HTML&lt;/h3&gt;
@ -458,12 +582,30 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>configuring a dynamic, modern, and minimal DIY wayland desktop environment with home-manager</title>
<link>http://localhost:1313/configuring-a-dynamic-modern-and-minimal-diy-wayland-desktop-environment-with-home-manager/</link>
<pubDate>Sun, 25 Jun 2023 00:00:00 +0000</pubDate>
<guid>http://localhost:1313/configuring-a-dynamic-modern-and-minimal-diy-wayland-desktop-environment-with-home-manager/</guid>
<description>&lt;h3 id=&#34;components&#34;&gt;components&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;hyprland (window manager)&lt;/li&gt;
&lt;li&gt;waybar (bar)&lt;/li&gt;
&lt;li&gt;wofi (application launcher)&lt;/li&gt;
&lt;li&gt;mako (notification daemon)&lt;/li&gt;
&lt;/ul&gt;
</description>
</item>
<item>
<title>Tailscale, caddy, and nixos containers</title>
<link>https://nonsense.dymc.win/tailscale-caddy-and-nixos-containers/</link>
<link>http://localhost:1313/tailscale-caddy-and-nixos-containers/</link>
<pubDate>Tue, 16 May 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/tailscale-caddy-and-nixos-containers/</guid>
<guid>http://localhost:1313/tailscale-caddy-and-nixos-containers/</guid>
<description>&lt;p&gt;For a little while now I&amp;rsquo;ve been running some services (jellyfin etc.) on an old laptop in my house. I&amp;rsquo;m not trying to sound like a podcast ad but as a networking novice, the simplicity &lt;a href=&#34;https://tailscale.com/&#34;&gt;tailscale&lt;/a&gt; brings to accessing these services remotely is very nice. Until recently though, I had been accessing my services like a heathen with http and port numbers (eg http://tailscale-ip:service-port). This works and is perfectly secure thanks to tailscale though it lacks a certain finesse. In an ideal world you&amp;rsquo;d have a reverse proxy and set up SSL certs so your browser doesn&amp;rsquo;t get stressed and you dont have to rememeber ip addresses and port numbers.&lt;/p&gt;
&lt;p&gt;When I initially looked at how to do this it seemed like it was above my paygrade and not worth the stress; that was until I came across &lt;a href=&#34;https://caddy.community/t/https-in-your-vpn-caddy-now-uses-tls-certificates-from-tailscale/15380&#34;&gt;this&lt;/a&gt;. This works great and is as simple as advertised though there is one drawback: you can only reverse proxy one service per host. So for my usecase of the laptop with multiple services running on it I could only use the magic caddy tailscale auto-https thing for one of them.&lt;/p&gt;
&lt;h3 id=&#34;what-to-do&#34;&gt;what to do?&lt;/h3&gt;
@ -529,10 +671,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Learning about qtile widgets with cricket</title>
<link>https://nonsense.dymc.win/learning-about-qtile-widgets-with-cricket/</link>
<link>http://localhost:1313/learning-about-qtile-widgets-with-cricket/</link>
<pubDate>Mon, 03 Apr 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/learning-about-qtile-widgets-with-cricket/</guid>
<guid>http://localhost:1313/learning-about-qtile-widgets-with-cricket/</guid>
<description>&lt;p&gt;I&amp;rsquo;m a person who has spent an unreasonable amount of time making minute changes to the appearance of my bar in qtile. Despite the very nice selection of widgets availabe by default with qtile, it was only a matter of time before I decided I wanted to experiment with making my own custom widget. Fortunately, if you can do a bit of python this is quite an approachable undertaking.&lt;/p&gt;
&lt;p&gt;The dream widget I was lacking was a little live crikcet score ticker type thing; something which would scroll along on my bar showing me the score in live cricket matches. I&amp;rsquo;m sure this will interest very few people but I learnt some good stuff along the way.&lt;/p&gt;
&lt;h3 id=&#34;hello-world&#34;&gt;Hello World?!&lt;/h3&gt;
@ -641,10 +783,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Achieve peak rice with nix-colors</title>
<link>https://nonsense.dymc.win/achieve-peak-rice-with-nix-colors/</link>
<link>http://localhost:1313/achieve-peak-rice-with-nix-colors/</link>
<pubDate>Mon, 13 Mar 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/achieve-peak-rice-with-nix-colors/</guid>
<guid>http://localhost:1313/achieve-peak-rice-with-nix-colors/</guid>
<description>&lt;p&gt;As I fall deeper and deeper down the nixos rabbit hole, I find myself becoming more and more obsessed with controlling every little thing on my computers declaratively. It starts with: &amp;lsquo;oh this is cool I can specify which desktop environment to use in my configuration.nix&amp;rsquo;. Next thing you know you&amp;rsquo;ve discovered &lt;a href=&#34;https://github.com/nix-community/home-manager&#34;&gt;home-manager&lt;/a&gt; and every program on every linux system you use needs to be controlled in your nix-config. Of course this slightly insane approach has its downsides; it also opens some doors though.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://sr.ht/~misterio/nix-colors/&#34;&gt;Nix-colors&lt;/a&gt; lets you dyanmically change the theming of programs controlled in your nix config. So when you want to change the color of everything and have it match and all be pretty lol, you are able to do so with one word as opposed to poring over everything changing each individual color. For a certain type of person, this is very nice!&lt;/p&gt;
&lt;h3 id=&#34;how-to-make-it-work&#34;&gt;how to make it work&lt;/h3&gt;
@ -738,12 +880,23 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>placeholder</title>
<link>http://localhost:1313/placeholder/</link>
<pubDate>Mon, 13 Mar 2023 00:00:00 +0000</pubDate>
<guid>http://localhost:1313/placeholder/</guid>
<description></description>
</item>
<item>
<title>Translating docker to nix?!</title>
<link>https://nonsense.dymc.win/translating-docker-to-nix/</link>
<link>http://localhost:1313/translating-docker-to-nix/</link>
<pubDate>Tue, 28 Feb 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/translating-docker-to-nix/</guid>
<guid>http://localhost:1313/translating-docker-to-nix/</guid>
<description>&lt;p&gt;In my opinion, there are moments when the convenience of docker and its surrounding ecosystem can&amp;rsquo;t be beat. I&amp;rsquo;ve been dabbling in the self hosting world and oftentimes the best maintained packaging option is a docker image. As a result of this I&amp;rsquo;ve been playing around with the nixos approach to managing docker containers.&lt;/p&gt;
&lt;h3 id=&#34;nix---docker-compose---docker-run&#34;&gt;nix -&amp;gt; docker compose -&amp;gt; docker run&lt;/h3&gt;
&lt;p&gt;To illustrate how to translate a simple example from the world of docker to nix let&amp;rsquo;s have a look at the config for my &lt;a href=&#34;https://docs.searxng.org/&#34;&gt;searxng&lt;/a&gt; instance.&lt;/p&gt;
@ -794,10 +947,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Simple nixos config for vps static site</title>
<link>https://nonsense.dymc.win/simple-nixos-config-for-vps-static-site/</link>
<link>http://localhost:1313/simple-nixos-config-for-vps-static-site/</link>
<pubDate>Sun, 29 Jan 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/simple-nixos-config-for-vps-static-site/</guid>
<guid>http://localhost:1313/simple-nixos-config-for-vps-static-site/</guid>
<description>&lt;p&gt;Setting up a little static site is something I&amp;rsquo;ve done a few different times on a few different operating systems. It&amp;rsquo;s a slightly fiddly task with a few disparate jobs that all need looking after: ssh, let&amp;rsquo;s encrypt, nginx. In my opinion, it is one of the moments where consolidating all the little bits and bobs you need to setup into one common configuration is very useful.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m going to go through a bit of the nixos config I&amp;rsquo;ve got for my vps.&lt;/p&gt;
&lt;h3 id=&#34;ssh&#34;&gt;SSH&lt;/h3&gt;
@ -854,10 +1007,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Python podcast scripting</title>
<link>https://nonsense.dymc.win/python-podcast-scripting/</link>
<link>http://localhost:1313/python-podcast-scripting/</link>
<pubDate>Tue, 24 Jan 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/python-podcast-scripting/</guid>
<guid>http://localhost:1313/python-podcast-scripting/</guid>
<description>&lt;p&gt;I have an old sad android phone with 2GB of ram which nowadays seems struggles these days. As a result of this I have been &amp;lsquo;podcast-player-hopping&amp;rsquo; without success for the last couple of months trying to find something which doesn&amp;rsquo;t nuke my phone whenever I use it. In a moment of desperation it occured to me that a creative solution might be required. The gameplan was this:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;write python script to download podcasts&lt;/li&gt;
@ -946,10 +1099,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Bread dough for lazy boys</title>
<link>https://nonsense.dymc.win/bread-dough-for-lazy-boys/</link>
<link>http://localhost:1313/bread-dough-for-lazy-boys/</link>
<pubDate>Sun, 22 Jan 2023 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/bread-dough-for-lazy-boys/</guid>
<guid>http://localhost:1313/bread-dough-for-lazy-boys/</guid>
<description>&lt;h3 id=&#34;ingredienti&#34;&gt;INGREDIENTI&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;flour (ideally bread flour but if you don&amp;rsquo;t have it, it&amp;rsquo;s not the end of the world)&lt;/li&gt;
@ -992,10 +1145,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Multi user qtile fiddling</title>
<link>https://nonsense.dymc.win/multi-user-qtile-fiddling/</link>
<link>http://localhost:1313/multi-user-qtile-fiddling/</link>
<pubDate>Tue, 20 Dec 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/multi-user-qtile-fiddling/</guid>
<guid>http://localhost:1313/multi-user-qtile-fiddling/</guid>
<description>&lt;p&gt;This post is going to detail how I solved a very particular problem I had created for myself. First, a quick description of the problem. I use home-manager on nixos to declaratively configure what happens on my computer. In the cases where home-manager does not expose sufficient configuration options for my liking (qtile for example), I instead link a configuration file from my nixos config to where it belongs in my home using &lt;code&gt;xdg.configFile&lt;/code&gt;. This is what I do with my qtile &lt;code&gt;config.py&lt;/code&gt;. I use qtile on my desktop and laptop but I dont want an identical setup on the two machines. I have jumped through many different slightly silly hoops in my nixos config sort of solving this problem until the other day it occured to me this could all be achieved with my python in my qtile config.&lt;/p&gt;
&lt;h3 id=&#34;the-nub-of-the-problem&#34;&gt;THE NUB OF THE PROBLEM&lt;/h3&gt;
&lt;p&gt;I basically just want the config to work out which computer it&amp;rsquo;&amp;rsquo;s on and then change some things accordingly. This can be achieved by getting the hostname with the socket module:&lt;/p&gt;
@ -1072,10 +1225,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Teeny tiny bash fetch script</title>
<link>https://nonsense.dymc.win/teeny-tiny-bash-fetch-script/</link>
<link>http://localhost:1313/teeny-tiny-bash-fetch-script/</link>
<pubDate>Sat, 10 Dec 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/teeny-tiny-bash-fetch-script/</guid>
<guid>http://localhost:1313/teeny-tiny-bash-fetch-script/</guid>
<description>&lt;p&gt;This is my attempt at a neofetch, pfetch, whateverfetch style system info utility. My main concern was making something which looked nice, was easily configurable, and as portable as possible (I didn&amp;rsquo;t really try that hard with the portability). I didn&amp;rsquo;t think much about performance; I&amp;rsquo;m personally not a man who stresses too much when a command takes a quarter of a second instead of a tenth. The basic gameplan was to get an array of bash commands which would fetch various bits and bobs, then loop through this array formatting the text with ANSI escape codes. First things first, this was the associative array I came up with:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nb&#34;&gt;declare&lt;/span&gt; -A &lt;span class=&#34;nv&#34;&gt;fetch&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=(&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;o&#34;&gt;[&lt;/span&gt;user&lt;span class=&#34;o&#34;&gt;]=&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$USER&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;
@ -1144,7 +1297,7 @@ After moving across most of my stuff I came across the problem of how to hook th
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;nb&#34;&gt;echo&lt;/span&gt; -e &lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span class=&#34;k&#34;&gt;$(&lt;/span&gt;random_color&lt;span class=&#34;k&#34;&gt;)&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt; \e[0;1;3m&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$info&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;\e[0m&lt;/span&gt;&lt;span class=&#34;si&#34;&gt;${&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;sep&lt;/span&gt;&lt;span class=&#34;si&#34;&gt;}${&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;fetch&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;&lt;span class=&#34;nv&#34;&gt;$info&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;]&lt;/span&gt;&lt;span class=&#34;si&#34;&gt;}&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;k&#34;&gt;done&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This had the happy unintended consequence of allowing you to very easily configure which items you wanted in the fetch by simply commenting out keys from the order array. You can check out the script in its entirety &lt;a href=&#34;https://gitlab.com/robbygozzarder/golazo&#34;&gt;here&lt;/a&gt;. This is a pretty picture of a few variations.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://nonsense.dymc.win/image/golazo.png&#34; alt=&#34;golazo&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://localhost:1313/image/golazo.png&#34; alt=&#34;golazo&#34;&gt;&lt;/p&gt;
</description>
</item>
@ -1152,10 +1305,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Get the thoughts out of your head and into a digital format with this python journalling script</title>
<link>https://nonsense.dymc.win/get-the-thoughts-out-of-your-head-and-into-a-digital-format-with-this-python-journalling-script/</link>
<link>http://localhost:1313/get-the-thoughts-out-of-your-head-and-into-a-digital-format-with-this-python-journalling-script/</link>
<pubDate>Thu, 01 Dec 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/get-the-thoughts-out-of-your-head-and-into-a-digital-format-with-this-python-journalling-script/</guid>
<guid>http://localhost:1313/get-the-thoughts-out-of-your-head-and-into-a-digital-format-with-this-python-journalling-script/</guid>
<description>&lt;p&gt;Since getting going with emacs I&amp;rsquo;ve gone down the org-mode rabbit hole a little bit. In particular the very nice &lt;a href=&#34;https://github.com/bastibe/org-journal&#34;&gt;org-journal&lt;/a&gt; package. It basically does what it says on the tin: maintains a journal with a selection of org files. This has been very nice for me. I have often thought about journalling but never really got up a head of steam. Somehow having an entry a keybinding away while I&amp;rsquo;m doing something with my text editor makes it a lot more palletable.&lt;/p&gt;
&lt;p&gt;Having said all this, I am not completely converted to the church of emacs. Thus, I thoght it would be nice to write a little editor agnostic script which would emulate some of org-journal&amp;rsquo;s features but allow you to use whatever editor you like with markdown.&lt;/p&gt;
&lt;h3 id=&#34;whats-the-time&#34;&gt;WHAT&amp;rsquo;S THE TIME?&lt;/h3&gt;
@ -1216,10 +1369,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Lowkey emacs setup bits and bobs</title>
<link>https://nonsense.dymc.win/lowkey-emacs-setup-bits-and-bobs/</link>
<link>http://localhost:1313/lowkey-emacs-setup-bits-and-bobs/</link>
<pubDate>Fri, 18 Nov 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/lowkey-emacs-setup-bits-and-bobs/</guid>
<guid>http://localhost:1313/lowkey-emacs-setup-bits-and-bobs/</guid>
<description>&lt;p&gt;About a month ago I was a little bored and thought I&amp;rsquo;d give emacs a go. There&amp;rsquo;s something fun about trying out these mythical pieces of software that have been around forever; kind of like watching The Godfather for the first time. Like many extensible, super configurable programs, emacs seems kind of impenetrable at first glance. I tried doing the tutorial but kind of glazed over after a while with the endless stream of C-a C-b C-c. There&amp;rsquo;s also the quite jarring default theme which wasn&amp;rsquo;t vibing with the lovely screenshots I had seen on the internet. Anyway, after quite a bit of fiddling I&amp;rsquo;ve landed on a simple little setup that I&amp;rsquo;ve been quite enjoying. Here are a few little pointers to hopefully ease you in.&lt;/p&gt;
&lt;h3 id=&#34;aesthetic-niceties&#34;&gt;AESTHETIC NICETIES&lt;/h3&gt;
&lt;p&gt;First things first, assuming you&amp;rsquo;re on linux emacs is configured with a file at &lt;code&gt;~/.emacs.d/init.el&lt;/code&gt;. As a terrible aesthete, the first thing I was worried about was changing the theme. This can be achieved with &lt;code&gt;M-x load-theme&lt;/code&gt;; if you want the setting to persist though you can add this to you init.el:&lt;/p&gt;
@ -1292,7 +1445,93 @@ After moving across most of my stuff I came across the problem of how to hook th
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-lisp&#34; data-lang=&#34;lisp&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;nf&#34;&gt;use-package&lt;/span&gt; &lt;span class=&#34;nv&#34;&gt;smart-comment&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;ss&#34;&gt;:bind&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;#34;M-c&amp;#34;&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;.&lt;/span&gt; &lt;span class=&#34;nv&#34;&gt;smart-comment&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;))&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Here&amp;rsquo;s a little pic of the current setup :)&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://nonsense.dymc.win/image/emacs.png&#34; alt=&#34;emacs&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://localhost:1313/image/emacs.png&#34; alt=&#34;emacs&#34;&gt;&lt;/p&gt;
</description>
</item>
<item>
<title>setting up a lean mean hugo blogging theme</title>
<link>http://localhost:1313/setting-up-a-lean-mean-hugo-blogging-theme/</link>
<pubDate>Thu, 10 Nov 2022 00:00:00 +0000</pubDate>
<guid>http://localhost:1313/setting-up-a-lean-mean-hugo-blogging-theme/</guid>
<description>&lt;p&gt;When I first started messing around with hugo, I found the whole thing slihtly mystifying. I downloaded a theme like they asked me, edited the config file to try and customise things a little and quickly broke everything. To be fair, this was mainly due to my tinkering instinct to fly to close to the sun. But anyway, the point at which I started to really appreciate the power of hugo was when I tried to make my own - admittedly less feautureful - theme. This selection of tips and tricks will assume that you&amp;rsquo;ve just run something like &lt;code&gt;hugo new site lovely-new-website&lt;/code&gt;, entered the new directory with &lt;code&gt;cd lovely-new-website&lt;/code&gt; and you&amp;rsquo;ve got a selection of mostly empty directories looking something like this.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;.
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;├── archetypes
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;│   └── default.md
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;├── config.toml
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;├── content
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;├── data
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;├── layouts
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;├── public
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;├── static
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;└── themes
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Our first concern will be getting a barebones theme template that can be customised to our liking. I would recommend &lt;a href=&#34;https://github.com/ericmurphyxyz/hugo-starter-theme&#34;&gt;this&lt;/a&gt; guy which I used to get up and running. You could also check out &lt;a href=&#34;https://gitlab.com/robbygozzarder/mcl&#34;&gt;my theme&lt;/a&gt; which I&amp;rsquo;m using on this site that is also very simple (as you can probably see from the website lol). Once you&amp;rsquo;ve got a theme with (I&amp;rsquo;m using mine as an example) &lt;code&gt;git clone https://gitlab.com/robbygozzarder/mcl&lt;/code&gt; and placed it in the themes directory you&amp;rsquo;ll need to adjust your config.toml file to point it to this theme.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-toml&#34; data-lang=&#34;toml&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nx&#34;&gt;theme&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;mcl&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The directory structure of your new theme will look something like this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;.
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;└── mcl
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; ├── archetypes
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   └── default.md
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; ├── layouts
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   ├── 404.html
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   ├── _default
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   │   ├── list.html
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   │   └── single.html
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   ├── index.html
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   └── partials
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   ├── footer.html
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   ├── header.html
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; │   └── nav.html
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; ├── README.md
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; └── static
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; └── css
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; └── style.css
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This is where most of the magic happens:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The default.md file in the archetypes directory dictates what template to follow when adding new post files.&lt;/li&gt;
&lt;li&gt;The layouts directory is where most of the meat is:
&lt;ul&gt;
&lt;li&gt;Firstly, there&amp;rsquo;s the partials directory which contains outlines for sections which you want to be used multiple times across the site such as a footer (footer.html)&lt;/li&gt;
&lt;li&gt;Sceondly, we have _default which contains outlines for the two types of hugo pages; singles (single.html) such as this individual post page, and lists (list.html) such as the tags and posts pages on this site.&lt;/li&gt;
&lt;li&gt;Partials also contains index.html which (you guessed it!) is your home page.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Last but not least, there&amp;rsquo;s static which as you can see just has the css for the site (this is all looks though - the action happens in partials).&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Now the theme is sorted the next three things you need to know anything about (imho) are the content, public, and static directories:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Content is where you put your posts - these are just markdown files which hugo converts to html for you.&lt;/li&gt;
&lt;li&gt;Public is where hugo puts your built - ready to be served - site. You can then copy this directory to wherever your webserver is looking eg. /var/www/jdysmcl&lt;/li&gt;
&lt;li&gt;Static is where assets which you want to use with your site are kept. I basically just use it for images which I can then reference from my posts.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Now we&amp;rsquo;ve got the directory what&amp;rsquo;s happening where admin out the way let&amp;rsquo;s have a look at what some of the html files in the themes directory look like; this is the index.html for my site for example:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-html&#34; data-lang=&#34;html&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;{{ partial &amp;#34;header.html&amp;#34; . }}
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;p&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;This is mainly a place for me to document various
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;bits and bobs I&amp;#39;ve been doing on my computers.
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;I am a noob in most things so take anything written
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;here with a pinch of salt. Lots of love :)&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;p&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;{{ .Content }}
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;{{ range .Site.RegularPages | first 5 }}
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h3&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;#34;{{ .RelPermalink }}&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;{{ .Title }}&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;h3&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; {{ .Summary }}
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;br&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;br&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; {{ .Date.Format &amp;#34;06 Jan, 2006&amp;#34; }} |
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; {{ .WordCount }} words |
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; {{ .ReadingTime }} mins |
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; {{ range (.GetTerms &amp;#34;tags&amp;#34;) }}
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;&amp;lt;&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt; &lt;span class=&#34;na&#34;&gt;href&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;=&lt;/span&gt;&lt;span class=&#34;s&#34;&gt;&amp;#39;{{ .Permalink }}&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;{{ .LinkTitle }}&lt;span class=&#34;p&#34;&gt;&amp;lt;/&lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;a&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;&amp;gt;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; {{ end }}
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;{{ end }}
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;{{ partial &amp;#34;footer.html&amp;#34; . }}
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;In short, this plops the header and footer partials at the top and bottom of the page respectively, includes a short warning not to listen to me, and then displays my five most recent posts along with a snippet of the post and some accompanyning info: date, word count, reading time, and tags. The keen eyed among you will have noticed that this is a mish mash of normal html tags and strange stuff enclosed in double curly brackets. I&amp;rsquo;m going to end on this cliffhanger but if you want to know more about the curly brackets check out the hugo docs &lt;a href=&#34;https://gohugo.io/templates/introduction&#34;&gt;here&lt;/a&gt;.&lt;/p&gt;
</description>
</item>
@ -1300,10 +1539,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>The search for en passant checkmates 2: Electric Boogaloo</title>
<link>https://nonsense.dymc.win/the-search-for-en-passant-checkmates-2-electric-boogaloo/</link>
<link>http://localhost:1313/the-search-for-en-passant-checkmates-2-electric-boogaloo/</link>
<pubDate>Tue, 08 Nov 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/the-search-for-en-passant-checkmates-2-electric-boogaloo/</guid>
<guid>http://localhost:1313/the-search-for-en-passant-checkmates-2-electric-boogaloo/</guid>
<description>&lt;p&gt;Last time we worked out how to get info for all the games played by titled players in a particular month. Today, we have three objectives:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Parse this info for the pgn (portable game notation) of each game.&lt;/li&gt;
@ -1326,7 +1565,7 @@ After moving across most of my stuff I came across the problem of how to hook th
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;k&#34;&gt;for&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;pgn&lt;/span&gt; &lt;span class=&#34;ow&#34;&gt;in&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;pgns&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;f&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;write&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;pgn&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now a pgn looks something like this if it&amp;rsquo;s just printed as a string:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://nonsense.dymc.win/image/pgn.webp&#34; alt=&#34;image alt text&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://localhost:1313/image/pgn.webp&#34; alt=&#34;image alt text&#34;&gt;&lt;/p&gt;
&lt;p&gt;It contains lots of very useful info but for our purposes of finding en passant checkmates, we would ideally just have a list of each move looking something like this:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;moves&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt; &lt;span class=&#34;s1&#34;&gt;&amp;#39;e4&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s1&#34;&gt;&amp;#39;e5&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s1&#34;&gt;&amp;#39;Bc4&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s1&#34;&gt;&amp;#39;Nc6&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s1&#34;&gt;&amp;#39;Qh5&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s1&#34;&gt;&amp;#39;Nf6&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s1&#34;&gt;&amp;#39;Qxf7#&amp;#39;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;]&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;We don&amp;rsquo;t need the headers, we don&amp;rsquo;t need the result, and we don&amp;rsquo;t really need the move numbers (these can be deduced from the list indexes). So the challenge is how to convert the pgn to a list; this is the slightly janky solution I came up wtih.&lt;/p&gt;
@ -1355,10 +1594,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>The search for en passant checkmates</title>
<link>https://nonsense.dymc.win/the-search-for-en-passant-checkmates/</link>
<link>http://localhost:1313/the-search-for-en-passant-checkmates/</link>
<pubDate>Wed, 26 Oct 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/the-search-for-en-passant-checkmates/</guid>
<guid>http://localhost:1313/the-search-for-en-passant-checkmates/</guid>
<description>&lt;p&gt;The chess.com API gives you access to a crazy amount of data on games played on the site. Armed with the knowledge that this data was at my fingertips, I set out to do what any sane person would do: find en passant checkmates. For those not in the know, en passant check mate is kind of the king of moves in chess meme circles. So some sort of python script that identified en passant check mates that occured on the site would be of great value to me.&lt;/p&gt;
&lt;p&gt;First things first, I would need a method of grabbing lots of games from the api. This would be achieved by looking at players on the site and searching their game archives. As I couldn&amp;rsquo;t think of any obvious way to get completely random players on the site, I used the API&amp;rsquo;s lists of all titled players (GM, IM, WIM, etc.) on the site. This is what I came up with -&amp;gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;k&#34;&gt;def&lt;/span&gt; &lt;span class=&#34;nf&#34;&gt;get_archive_urls&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;titled_urls&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;):&lt;/span&gt;
@ -1393,7 +1632,7 @@ After moving across most of my stuff I came across the problem of how to hook th
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;s1&#34;&gt;&amp;#39;https://api.chess.com/pub/titled/WGM&amp;#39;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;]))&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;We get a very long list of json objects (is that the right phrase? um). Each corresponding to one of games played by GMs and WGMs on chess.com during May of 2022. Come back next time to see what we can do with this very long list. Here&amp;rsquo;s a taster of what the list looks like printed to a terminal - lots of possiblities.&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://nonsense.dymc.win/image/output.webp&#34; alt=&#34;image alt text&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://localhost:1313/image/output.webp&#34; alt=&#34;image alt text&#34;&gt;&lt;/p&gt;
</description>
</item>
@ -1401,10 +1640,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Declarative firefox config with home-manager on nixos</title>
<link>https://nonsense.dymc.win/declarative-firefox-config-with-home-manager-on-nixos/</link>
<link>http://localhost:1313/declarative-firefox-config-with-home-manager-on-nixos/</link>
<pubDate>Sun, 02 Oct 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/declarative-firefox-config-with-home-manager-on-nixos/</guid>
<guid>http://localhost:1313/declarative-firefox-config-with-home-manager-on-nixos/</guid>
<description>&lt;p&gt;As a man who finds himself reinstalling his OS more than is probably sensible, any opportunity to minimise the post install admin of sorting out all your settings is an attractive one. With that in mind lets take a look at some of the firefox (my current browser of choice) configuration options avilable to you through home-manager. This assumes you have some sort of home-manager setup working. If you do not I found &lt;a href=&#34;https://github.com/misterio77/nix-starter-configs&#34;&gt;this&lt;/a&gt; friendly githubber&amp;rsquo;s templates to be very helpful.&lt;/p&gt;
&lt;p&gt;First of all you&amp;rsquo;ll need to enable firefox with &lt;code&gt;programs.firefox.enable = true;&lt;/code&gt;&lt;/p&gt;
&lt;h3 id=&#34;extensions&#34;&gt;EXTENSIONS&lt;/h3&gt;
@ -1467,10 +1706,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Upgrade your qtile setup with a cute dropdown terminal</title>
<link>https://nonsense.dymc.win/upgrade-your-qtile-setup-with-a-cute-dropdown-terminal/</link>
<link>http://localhost:1313/upgrade-your-qtile-setup-with-a-cute-dropdown-terminal/</link>
<pubDate>Fri, 23 Sep 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/upgrade-your-qtile-setup-with-a-cute-dropdown-terminal/</guid>
<guid>http://localhost:1313/upgrade-your-qtile-setup-with-a-cute-dropdown-terminal/</guid>
<description>&lt;p&gt;I didn&amp;rsquo;t know you could do this until recently, very fun and playful little feature. How you want to do it will depend slightly on how you have your groups set up but I start with importing the relevant libraries and defining an empty list.&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;kn&#34;&gt;from&lt;/span&gt; &lt;span class=&#34;nn&#34;&gt;libqtile.config&lt;/span&gt; &lt;span class=&#34;kn&#34;&gt;import&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;Dropdown&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;n&#34;&gt;Scratchpad&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
@ -1487,7 +1726,7 @@ After moving across most of my stuff I came across the problem of how to hook th
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;),&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This gives you a terminal (kitty in this case) with a little tranparency. By default, it will pop up with this size:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://nonsense.dymc.win/image/dropdown.webp&#34; alt=&#34;alt&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://localhost:1313/image/dropdown.webp&#34; alt=&#34;alt&#34;&gt;&lt;/p&gt;
&lt;p&gt;Though this can easily be altered with the x, y, height, and width keys:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;groups&lt;/span&gt;&lt;span class=&#34;o&#34;&gt;.&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;append&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;ScratchPad&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;(&lt;/span&gt;&lt;span class=&#34;s2&#34;&gt;&amp;#34;scratchpad&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;
@ -1503,7 +1742,7 @@ After moving across most of my stuff I came across the problem of how to hook th
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;p&#34;&gt;])&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;p&#34;&gt;)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;This gives us a little boxy guy in the top left corner:&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;https://nonsense.dymc.win/image/dropdown2.webp&#34; alt=&#34;alt&#34;&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src=&#34;http://localhost:1313/image/dropdown2.webp&#34; alt=&#34;alt&#34;&gt;&lt;/p&gt;
&lt;p&gt;We also have the option to set keybindings to toggle the appearance of the window. I&amp;rsquo;ve got this in my config.py now:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-python&#34; data-lang=&#34;python&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;n&#34;&gt;keys&lt;/span&gt; &lt;span class=&#34;o&#34;&gt;=&lt;/span&gt; &lt;span class=&#34;p&#34;&gt;[&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt; &lt;span class=&#34;n&#34;&gt;Key&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;([&lt;/span&gt;&lt;span class=&#34;n&#34;&gt;m&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;shift&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;],&lt;/span&gt; &lt;span class=&#34;s2&#34;&gt;&amp;#34;Return&amp;#34;&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;,&lt;/span&gt;
@ -1519,10 +1758,10 @@ After moving across most of my stuff I came across the problem of how to hook th
<item>
<title>Rudimentary local scrobbling with bash</title>
<link>https://nonsense.dymc.win/rudimentary-local-scrobbling-with-bash/</link>
<link>http://localhost:1313/rudimentary-local-scrobbling-with-bash/</link>
<pubDate>Tue, 13 Sep 2022 00:00:00 +0000</pubDate>
<guid>https://nonsense.dymc.win/rudimentary-local-scrobbling-with-bash/</guid>
<guid>http://localhost:1313/rudimentary-local-scrobbling-with-bash/</guid>
<description>&lt;p&gt;There are lots of music players on linux. I have used lots of them, I quite like some of them. But for some reason I decided I wanted more. With this in mind, over the past few months I have been constructing a sprawling ecosystem of bash scripts all geared towards delivering a customised listening experience tailored perfectly to my every need. In short, the setup uses a simple dmenu file manager to browse my local files and mpv to play them. Today I&amp;rsquo;ll be talking specifically about my setup for recording the albums I&amp;rsquo;ve been listening to.&lt;/p&gt;
&lt;h3 id=&#34;lets-get-down-to-business&#34;&gt;LET&amp;rsquo;S GET DOWN TO BUSINESS&lt;/h3&gt;
&lt;p&gt;Whenever I select a file to be played with my script I am effectively selecting a path to a file or a path to a directory with files in it which is then fed to mpv. For example, if I&amp;rsquo;m playing the classic album Lemonade by Beyonce it would look like this:&lt;/p&gt;