<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Samodra · Stories</title><description>Software Engineer based in Indonesia, specializing in web development with Ruby on Rails and Next.js.</description><link>https://samodra.my.id/</link><item><title>Moving my lessons site from Vercel to Cloudflare Pages</title><link>https://samodra.my.id/stories/vercel-to-cloudflare-pages/</link><guid isPermaLink="true">https://samodra.my.id/stories/vercel-to-cloudflare-pages/</guid><description>Vercel nearly paused my lessons site over ISR reads, even though it had few visitors. Sidebar prefetch was the cause, and since the content is almost all static, I moved it to Cloudflare Pages and Workers.</description><pubDate>Fri, 16 Oct 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;My lessons site almost got paused by Vercel, and it doesn’t get that many visitors.&lt;/p&gt;
&lt;p&gt;The warning came as an email. My ISR Reads had reached 75% of the 1 million limit on the free plan. If usage hit 100%, the site would be paused. It is not a paid site either, so upgrading the Vercel plan was not a real fix.&lt;/p&gt;
&lt;p&gt;&lt;img alt=&quot;A Vercel email titled “Your site is growing!” saying the free team has used 75% of the included free tier usage for Fast Origin Transfer (10 GB), and that projects will be paused automatically if the free usage is exceeded&quot; loading=&quot;lazy&quot; decoding=&quot;async&quot; width=&quot;1436&quot; height=&quot;442&quot; src=&quot;https://samodra.my.id/_astro/vercel-usage-email.JHvGeaK1_1WY00N.webp&quot;&gt;&lt;/p&gt;
&lt;p&gt;The email in the screenshot is a similar notice, for Fast Origin Transfer (10 GB) on the same free team. The same warning applies: go past the free usage and the projects are paused automatically, or upgrade to Pro.&lt;/p&gt;
&lt;h2 id=&quot;where-the-reads-came-from&quot;&gt;Where the reads came from&lt;/h2&gt;
&lt;p&gt;I audited the site again. The sidebar holds hundreds of links to lesson pages, and Next.js automatically prefetches the pages whose links are visible on screen. So a single visitor opening the site can trigger a dozen or more page reads within seconds.&lt;/p&gt;
&lt;p&gt;The site has about 1,140 lesson pages. In the infographic below, that works out to one visit turning into 10+ page reads within seconds, and 75% of the ISR Reads limit gone.&lt;/p&gt;
&lt;h2 id=&quot;why-static-was-the-better-fit&quot;&gt;Why static was the better fit&lt;/h2&gt;
&lt;p&gt;Looking at what the site actually contains, almost everything is static, and the lessons rarely change. Rendering them through SSR and ISR on every request was more machinery than the content needed.&lt;/p&gt;
&lt;p&gt;So I moved it to Cloudflare Pages:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;The lessons become fully static.&lt;/strong&gt; I exported them as a static site on Pages, so every lesson is a plain file served from the CDN.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The part that needs a server is small.&lt;/strong&gt; Learning progress and reviews are the only things that need a backend, so I migrated those to a small Hono API on Cloudflare Workers.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Both pieces fit in Cloudflare’s free plan.&lt;/p&gt;
&lt;p&gt;&lt;img alt=&quot;Before and after comparison. Before: Vercel Hobby, one Next.js app with SSR, ISR and API routes, about 1,140 lesson pages, ISR Reads at 75% of the 1M limit. After: Cloudflare Free, a static export on Pages plus a small Hono API on Workers. The static export shrank from 11,596 to 5,926 files and from 3,177 MiB to 304 MiB&quot; loading=&quot;lazy&quot; decoding=&quot;async&quot; width=&quot;1080&quot; height=&quot;1080&quot; src=&quot;https://samodra.my.id/_astro/vercel-to-cloudflare.BaxJl3_O_Z1fbEB6.webp&quot;&gt;&lt;/p&gt;
&lt;h2 id=&quot;trimming-the-export&quot;&gt;Trimming the export&lt;/h2&gt;
&lt;p&gt;I also trimmed the static export. It went from 11,596 files to 5,926, and from 3,177 MiB to 304 MiB.&lt;/p&gt;
&lt;h2 id=&quot;what-i-gave-up&quot;&gt;What I gave up&lt;/h2&gt;
&lt;p&gt;The downside is deployment. For now I deploy manually from my laptop, and it is not automatic the way it was on Vercel.&lt;/p&gt;
&lt;p&gt;I’m also curious whether anyone else has hit a plan limit because of prefetch. If it has happened to you, I’d like to hear how you handled it.&lt;/p&gt;
</content:encoded><category>cloudflare</category><category>vercel</category><category>infra</category></item><item><title>Replacing Gmail polling with email forwarding</title><link>https://samodra.my.id/stories/gmail-polling-to-email-forwarding/</link><guid isPermaLink="true">https://samodra.my.id/stories/gmail-polling-to-email-forwarding/</guid><description>My expense tracker checked Gmail every hour for new receipts. I flipped the flow so Gmail forwards each receipt to the backend through Cloudflare Email Routing, at the cost of a more involved setup.</description><pubDate>Tue, 13 Oct 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;For a while, my expense tracker looked for new receipts by checking Gmail once an hour. A scheduled job asked Gmail whether there was anything new, picked up whatever had arrived, and recorded it.&lt;/p&gt;
&lt;p&gt;It worked. It also felt inefficient, because the app kept going back to ask “any new email?”, and most of the time the answer was no.&lt;/p&gt;
&lt;h2 id=&quot;before-the-app-asks&quot;&gt;Before: the app asks&lt;/h2&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;plaintext&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span&gt;every hour:&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;  app  -&amp;gt;  Gmail   &quot;any new receipts?&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;  app  &amp;lt;-  Gmail   emails (or nothing)&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;  app  -&amp;gt;  record transactions&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Polling has a built-in delay. A receipt that arrives right after a check waits for the next one, so a transaction can show up an hour late.&lt;/p&gt;
&lt;h2 id=&quot;after-the-email-is-pushed&quot;&gt;After: the email is pushed&lt;/h2&gt;
&lt;p&gt;I brainstormed the problem with an LLM, and the result was to reverse the direction of the flow. Now Gmail forwards each receipt to my backend through Cloudflare Email Routing, and the app only has to wait for the email to arrive.&lt;/p&gt;
&lt;p&gt;&lt;img alt=&quot;A five-step diagram: the app generates a receipt address and registers it to a wallet, Gmail auto-forwards matching receipts to that address, Cloudflare receives the email and sends its content to the backend, the backend parses the receipt and stores the transaction, and the wallet is updated and a Telegram notification is sent&quot; loading=&quot;lazy&quot; decoding=&quot;async&quot; width=&quot;1254&quot; height=&quot;1254&quot; src=&quot;https://samodra.my.id/_astro/email-forwarding-flow.CfhQA8fD_Z2eYaLy.webp&quot;&gt;&lt;/p&gt;
&lt;p&gt;The flow, step by step:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Generate an address and register it.&lt;/strong&gt; The app creates a receipt email address and registers it to a wallet.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Set up Gmail auto-forward.&lt;/strong&gt; A Gmail filter matches receipt emails (by sender, for example) and forwards them to that address.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Email to Cloudflare.&lt;/strong&gt; The forwarded receipt arrives at Cloudflare, which sends the email content on to the backend.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Parse and store.&lt;/strong&gt; The backend parses the receipt, extracts the transaction and stores it in the database.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Wallet updated and notified.&lt;/strong&gt; The wallet is updated, and a notification goes out to Telegram.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Everything after the email lands happens in one pass. There is no cron job in the middle, so recording a transaction is much closer to real time.&lt;/p&gt;
&lt;h2 id=&quot;the-trade-off&quot;&gt;The trade-off&lt;/h2&gt;
&lt;p&gt;This is not free. The setup is more involved, because each wallet needs its own forwarding address, and the forwarding has to be registered one by one (steps 1 and 2 above). With polling, one job looked at one mailbox. With forwarding, a wallet’s receipts only reach the backend after its address and Gmail filter are in place.&lt;/p&gt;
&lt;p&gt;For an app that records transactions and sends notifications, I think the faster response is worth the extra setup. If I had many more wallets, I would want to make that registration step less manual.&lt;/p&gt;
</content:encoded><category>backend</category><category>cloudflare</category></item><item><title>What I changed when I cleaned up my dotfiles</title><link>https://samodra.my.id/stories/refactoring-my-dotfiles/</link><guid isPermaLink="true">https://samodra.my.id/stories/refactoring-my-dotfiles/</guid><description>I only wanted to publish my dotfiles on GitHub. That turned into four fixes: keeping secrets out of history, templating per OS, applying config instead of mirroring it, and sorting my scripts.</description><pubDate>Wed, 23 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;I started with a small goal: tidy my dotfiles so I could put them on GitHub. Once I looked at what was in there, I found the setup was messier than I remembered.&lt;/p&gt;
&lt;p&gt;My old backup script copied folders and files as they were, and Chezmoi replaced it. The change came down to four problems and what I did about each one.&lt;/p&gt;
&lt;h2 id=&quot;1-secrets-could-end-up-in-the-repo-history&quot;&gt;1. Secrets could end up in the repo history&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Before.&lt;/strong&gt; If a password, token or API key sits in &lt;code&gt;.zshrc&lt;/code&gt;, &lt;code&gt;.bashrc&lt;/code&gt; or any other shell config file, a raw &lt;code&gt;rsync&lt;/code&gt; or &lt;code&gt;cp&lt;/code&gt; backup can carry that value straight into the repo. Once it is committed, it is in the history:&lt;/p&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;diff&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;git show HEAD&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#22863A;--shiki-dark:#85E89D&quot;&gt;&lt;span style=&quot;user-select: none;&quot;&gt;+&lt;/span&gt; export API_KEY=&quot;sk-...&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#22863A;--shiki-dark:#85E89D&quot;&gt;&lt;span style=&quot;user-select: none;&quot;&gt;+&lt;/span&gt; export GITHUB_TOKEN=&quot;ghp_...&quot;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;After.&lt;/strong&gt; Environment variables are separate from shell configuration. Sensitive values live in files like &lt;code&gt;.zshrc.local&lt;/code&gt; or &lt;code&gt;.env&lt;/code&gt;. Git ignores both, and I manage them locally on each device:&lt;/p&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;plaintext&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span&gt;~/.zshrc.local   # ignored&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;~/.env           # ignored&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;My rule now is that &lt;code&gt;.zshrc&lt;/code&gt; holds shell configuration and nothing else. &lt;code&gt;.zshrc.local&lt;/code&gt; holds settings that belong to one machine, &lt;code&gt;.env&lt;/code&gt; holds the variables individual scripts use, and secret files stay local and are listed in &lt;code&gt;.gitignore&lt;/code&gt;.&lt;/p&gt;
&lt;h2 id=&quot;2-everything-piled-up-in-zshrc&quot;&gt;2. Everything piled up in &lt;code&gt;.zshrc&lt;/code&gt;&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Before.&lt;/strong&gt; Aliases, &lt;code&gt;PATH&lt;/code&gt; entries and secret values all lived in one file, with a question mark about which OS each line was for:&lt;/p&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;sh&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#6A737D;--shiki-dark:#6A737D&quot;&gt;# ~/.zshrc&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;export&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; PATH&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;/opt/homebrew/bin:&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;$PATH&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;export&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; PATH&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;$HOME&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;/.local/bin:&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;$PATH&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;export&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; DB_PASSWORD&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;supersecret&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#6A737D;--shiki-dark:#6A737D&quot;&gt;# macOS? Linux?&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;After.&lt;/strong&gt; One source file, with the platform branches written out. The global configuration stays in one place, and the macOS and Linux parts are explicit. Chezmoi templates make that possible:&lt;/p&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;sh&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#6A737D;--shiki-dark:#6A737D&quot;&gt;# dot_zshrc.tmpl&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;export&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; EDITOR&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;nvim&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;{{ if eq .chezmoi.os &quot;darwin&quot; }}&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;  export&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; PATH&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;/opt/homebrew/bin:&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;$PATH&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;{{ else if eq .chezmoi.os &quot;linux&quot; }}&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;  export&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt; PATH&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;=&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;$HOME&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;/.local/bin:&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;$PATH&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;&quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;{{ end }}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;code&gt;dot_zshrc.tmpl&lt;/code&gt; is still easy to read, and I no longer have to guess which line applies to which machine.&lt;/p&gt;
&lt;h2 id=&quot;3-sync-could-overwrite-whole-files&quot;&gt;3. Sync could overwrite whole files&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Before.&lt;/strong&gt; Running &lt;code&gt;rsync&lt;/code&gt; or &lt;code&gt;cp&lt;/code&gt; from a different machine can overwrite an existing file, the whole file at once. The &lt;code&gt;--delete&lt;/code&gt; flag makes it worse, and the same command run in the opposite direction does the same damage the other way:&lt;/p&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;sh&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#6F42C1;--shiki-dark:#B392F0&quot;&gt;rsync&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt; -av&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt; --delete&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt; ~/dotfiles/&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt; user@linux:~/&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#6A737D;--shiki-dark:#6A737D&quot;&gt;# or worse, the other direction...&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;After.&lt;/strong&gt; The configuration state is applied, not mirrored. Chezmoi makes the repository the managed source of configuration, and each machine applies it according to its own environment. On a new device that is one command:&lt;/p&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;sh&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span style=&quot;color:#6F42C1;--shiki-dark:#B392F0&quot;&gt;chezmoi&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt; init&lt;/span&gt;&lt;span style=&quot;color:#005CC5;--shiki-dark:#79B8FF&quot;&gt; --apply&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt; &amp;lt;&lt;/span&gt;&lt;span style=&quot;color:#032F62;--shiki-dark:#9ECBFF&quot;&gt;github-usernam&lt;/span&gt;&lt;span style=&quot;color:#24292E;--shiki-dark:#E1E4E8&quot;&gt;e&lt;/span&gt;&lt;span style=&quot;color:#D73A49;--shiki-dark:#F97583&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;h2 id=&quot;4-custom-scripts-were-mixed-together&quot;&gt;4. Custom scripts were mixed together&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;Before.&lt;/strong&gt; My scripts had inconsistent names, and scripts for different platforms sat side by side. It was hard to tell which one was safe to run on a given machine:&lt;/p&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;plaintext&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span&gt;scripts/&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;├── backup.sh&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;├── mac-setup.sh&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;├── setup_linux.sh&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;├── install&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;└── update_dotfiles_v2.sh&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;After.&lt;/strong&gt; Custom scripts are grouped by platform, and general scripts stay in the root &lt;code&gt;scripts&lt;/code&gt; folder:&lt;/p&gt;
&lt;pre class=&quot;astro-code astro-code-themes github-light github-dark&quot; style=&quot;background-color:#fff;--shiki-dark-bg:#24292e;color:#24292e;--shiki-dark:#e1e4e8; overflow-x: auto;&quot; tabindex=&quot;0&quot; data-language=&quot;plaintext&quot;&gt;&lt;code&gt;&lt;span class=&quot;line&quot;&gt;&lt;span&gt;scripts/&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;├── linux/&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;│   ├── setup.sh&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;│   └── install-deps.sh&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;├── macos/&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;│   ├── setup.sh&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;│   └── install-deps.sh&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;└── common/&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line&quot;&gt;&lt;span&gt;    └── utils.sh&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The same idea covers the rest of the OS-specific configuration, including the Linux desktop settings. It is kept apart from what both systems share.&lt;/p&gt;
&lt;h2 id=&quot;what-git-manages&quot;&gt;What Git manages&lt;/h2&gt;
&lt;p&gt;The sentence I keep coming back to is this: what Git manages is the configuration, not the entire state of my device. My old backup treated the two as the same thing, which is how secrets ended up next to shell settings. Now the repo holds what I want to reproduce on any machine, and everything specific to one machine stays on that machine.&lt;/p&gt;
</content:encoded><category>dotfiles</category><category>devtools</category></item><item><title>Herdr is more than a tmux replacement</title><link>https://samodra.my.id/stories/herdr-multi-agent-orchestration/</link><guid isPermaLink="true">https://samodra.my.id/stories/herdr-multi-agent-orchestration/</guid><description>I used Herdr as a tmux replacement until one prompt made it spawn four agents in four git worktrees and open four PRs. Notes on running agents in parallel with Orca and Herdr.</description><pubDate>Mon, 14 Sep 2026 00:00:00 GMT</pubDate><content:encoded>&lt;p&gt;By “agent orchestrator” I mean a tool that starts several coding agents at once, gives each one its own task and its own copy of the repo, and lets you watch all of them from one place. I have been trying two of them, Orca and Herdr.&lt;/p&gt;
&lt;h2 id=&quot;orca-parallel-github-issues&quot;&gt;Orca: parallel GitHub issues&lt;/h2&gt;
&lt;p&gt;I have been getting used to Orca. What I like is that it executes GitHub issues in parallel, so I don’t have to manage a pile of terminals and worktrees by hand. There is also a mobile app, which means I can check on an agent’s progress from my phone.&lt;/p&gt;
&lt;p&gt;In one project I split an offline-first sync feature into milestones, and each milestone got its own session in its own worktree. I could see which ones had delivered and which were still running.&lt;/p&gt;
&lt;p&gt;&lt;img alt=&quot;Orca on desktop: the sidebar lists the offline-first milestones as separate worktrees with an agent running in each, and a planning document is open on the right&quot; loading=&quot;lazy&quot; decoding=&quot;async&quot; width=&quot;1439&quot; height=&quot;1576&quot; src=&quot;https://samodra.my.id/_astro/orca-desktop.DD42WQxH_Ze4ofa.webp&quot;&gt;&lt;/p&gt;
&lt;h2 id=&quot;herdr-terminal-based-so-it-runs-on-a-cloud-machine&quot;&gt;Herdr: terminal-based, so it runs on a cloud machine&lt;/h2&gt;
&lt;p&gt;I had been using Herdr only to replace tmux. Several people suggested it as an orchestrator, and the reason I wanted to try it is that it is terminal based. That means I can install it on a cloud machine, which a desktop app does not give me.&lt;/p&gt;
&lt;p&gt;So I gave it one prompt that asked for four tasks at once:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Use herdr skills, do the task #1, #4, #5, #6. Each task should be in a new tab and git worktree. Run the tasks using agy. Once you are done with the task, commit it and create a PR.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I did not expect it to work on the first try, but it did. It opened four tabs, created a git worktree for each task, started an agent in each one, and then committed and opened a pull request per task.&lt;/p&gt;
&lt;p&gt;&lt;img alt=&quot;Herdr with four task tabs open (pre-commit, smoke-test, sentry, error-boundaries) and the agent’s pull request summary listing four branches and PRs #147 to #150&quot; loading=&quot;lazy&quot; decoding=&quot;async&quot; width=&quot;1090&quot; height=&quot;372&quot; src=&quot;https://samodra.my.id/_astro/herdr-pr-summary.DDWQ7jS7_1fDkEI.webp&quot;&gt;&lt;/p&gt;
&lt;p&gt;The same summary as a table:&lt;/p&gt;
&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Task&lt;/th&gt;
&lt;th&gt;Branch&lt;/th&gt;
&lt;th&gt;PR&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;#1 Git pre-commit hooks&lt;/td&gt;
&lt;td&gt;&lt;code&gt;feat/husky-pre-commit-hooks&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;#147&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;#5 Sentry error monitoring&lt;/td&gt;
&lt;td&gt;&lt;code&gt;feat/sentry-nextjs-integration&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;#148&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;#4 Preview deployment smoke test&lt;/td&gt;
&lt;td&gt;&lt;code&gt;feat/vercel-preview-smoke-test&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;#149&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;#6 App Router error boundaries&lt;/td&gt;
&lt;td&gt;&lt;code&gt;feat/nextjs-error-boundaries&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;#150&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;CI was green on three of them. The smoke test PR had been tested live, with CI still running when I took the screenshot.&lt;/p&gt;
&lt;p&gt;As far as I can tell, the “herdr skills” part of the prompt is what lets the agent drive Herdr on its own: it opens the tabs itself instead of me doing it.&lt;/p&gt;
&lt;h2 id=&quot;what-i-am-taking-from-this&quot;&gt;What I am taking from this&lt;/h2&gt;
&lt;p&gt;Here the prompt is the orchestration. I list the task numbers, say how each one should be isolated, and say what “done” means (commit and open a PR).&lt;/p&gt;
&lt;p&gt;Isolation matters here. Each agent works in its own worktree, so four agents never write to the same checkout, and each PR comes from its own branch.&lt;/p&gt;
&lt;p&gt;This was one run, with four tasks that did not overlap: hooks, monitoring, a smoke test, and error boundaries. I don’t know yet how it behaves when two tasks touch the same files, or when one task depends on another.&lt;/p&gt;
&lt;h2 id=&quot;next&quot;&gt;Next&lt;/h2&gt;
&lt;p&gt;I want to try a few Herdr plugins to make this workflow easier. If you have a plugin worth trying, or you use something else as your agent orchestrator, tell me.&lt;/p&gt;
</content:encoded><category>agents</category><category>devtools</category></item></channel></rss>