<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:googleplay="http://www.google.com/schemas/play-podcasts/1.0"><channel><title><![CDATA[Divyendu’s Notes]]></title><description><![CDATA[On Life and Technology]]></description><link>https://blog.divyendusingh.com</link><image><url>https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png</url><title>Divyendu’s Notes</title><link>https://blog.divyendusingh.com</link></image><generator>Substack</generator><lastBuildDate>Sat, 25 Apr 2026 12:12:28 GMT</lastBuildDate><atom:link href="https://blog.divyendusingh.com/feed" rel="self" type="application/rss+xml"/><copyright><![CDATA[Divyendu Singh]]></copyright><language><![CDATA[en]]></language><webMaster><![CDATA[divyenduz@substack.com]]></webMaster><itunes:owner><itunes:email><![CDATA[divyenduz@substack.com]]></itunes:email><itunes:name><![CDATA[Divyendu Singh]]></itunes:name></itunes:owner><itunes:author><![CDATA[Divyendu Singh]]></itunes:author><googleplay:owner><![CDATA[divyenduz@substack.com]]></googleplay:owner><googleplay:email><![CDATA[divyenduz@substack.com]]></googleplay:email><googleplay:author><![CDATA[Divyendu Singh]]></googleplay:author><itunes:block><![CDATA[Yes]]></itunes:block><item><title><![CDATA[Getting into split keyboards using two cheap keyboards]]></title><description><![CDATA[Validating the mechanical keyboard rabbit hole using thick paper, two Logitechs, and Karabiner-Elements.]]></description><link>https://blog.divyendusingh.com/p/split-keyboards</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/split-keyboards</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Fri, 03 Apr 2026 08:04:24 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!Ni1l!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Until recently (like 3 weeks ago), my keyboard philosophy was relatively simple. Buy a cheap, decent keyboard (+ mouse combo) which is durable. Keep 3-4 copies of it for frequently visited places (home, parents&#8217; home, one always in bag for co-working spaces etc.). For the last 10 years, I have had the following keyboards:</p><ul><li><p>Logitech MK240 Nano x 3 ($20 per piece)</p></li><li><p>Logitech Pebble 2 Combo x 3 ($60 per piece)</p></li></ul><p>See, this is modest and I was relatively happy with my setup. I don&#8217;t suffer from RSI or wrist issues (yet). Maybe because I don&#8217;t touch type? However, I do suffer from shoulder fatigue / feeling my chest is closed / squeezed (because mobile, compact keyboards).</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Divyendu&#8217;s Notes is a reader-supported publication. To receive new posts and support my work, consider becoming a free or paid subscriber.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>But I was conveniently ignoring all this, including some of my friends who swear by the split / ergonomic keyboards. But a few days ago, a <a href="https://richardgill.org/blog/3d-printing-a-keyboard">colleague 3D printed his own keyboard</a> and my inspiration to look into split keyboards was re-ignited.</p><p>Anyways, three weeks in, this post is about my approach to getting into the split keyboards rabbit hole and some tips for those who are just getting started like me.</p><h2>Validating the idea</h2><p>Before even diving into all the resources above and spending &#8220;dozens of dollars&#8221; as a colleague called it, I wanted to see if any kind of split would make sense for me / how would that feel. So I did something hacky / funny (but surprisingly functional).</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Ni1l!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Ni1l!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg 424w, https://substackcdn.com/image/fetch/$s_!Ni1l!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg 848w, https://substackcdn.com/image/fetch/$s_!Ni1l!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg 1272w, https://substackcdn.com/image/fetch/$s_!Ni1l!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Ni1l!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg" width="1456" height="819" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/fc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:819,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:4340365,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/jpeg&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:&quot;https://blog.divyendusingh.com/i/193040918?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Ni1l!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg 424w, https://substackcdn.com/image/fetch/$s_!Ni1l!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg 848w, https://substackcdn.com/image/fetch/$s_!Ni1l!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg 1272w, https://substackcdn.com/image/fetch/$s_!Ni1l!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ffc0a735c-a3a5-4898-a361-baa2c9512701_8064x4536.jpeg 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption">Testing split keyboard by using two separate keyboards</figcaption></figure></div><p>I connected two Bluetooth keyboards and used thick paper to block the keys as a split would have. It took me only ~30 minutes to get used to this setup and I could already feel the benefits of chest opening up because of the split. There was no going back from here. </p><p>But there was a problem (not visual, but functional). Since these are two keyboards connected separately to the laptop over Bluetooth, the modifier keys don&#8217;t work across the keyboards i.e. shift (left keyboard) + p (right keyboard) to print P. This was an annoyance, for the first time I was using right shift and other &#8220;redundant keys&#8221; on both sides.</p><p>Luckily, there is a nice (almost turnkey) software solution to this. It is called <a href="https://karabiner-elements.pqrs.org/">Karabiner-Elements</a>. It automatically detects all connected keyboards and other input devices and all I had to do was to toggle &#8220;Modify events&#8221; on. This was enough to share modifier key state between the two physical and completely separate keyboards. </p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!rk7f!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!rk7f!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png 424w, https://substackcdn.com/image/fetch/$s_!rk7f!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png 848w, https://substackcdn.com/image/fetch/$s_!rk7f!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png 1272w, https://substackcdn.com/image/fetch/$s_!rk7f!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!rk7f!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png" width="1456" height="1416" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/deb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:1416,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:444016,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://blog.divyendusingh.com/i/193040918?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!rk7f!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png 424w, https://substackcdn.com/image/fetch/$s_!rk7f!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png 848w, https://substackcdn.com/image/fetch/$s_!rk7f!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png 1272w, https://substackcdn.com/image/fetch/$s_!rk7f!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fdeb61ca2-b2bf-4d24-835b-da24e40f09a9_1616x1572.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption">My settings of Karabiner-Elements</figcaption></figure></div><h2>Strategy / Plan</h2><p>Based on the <a href="https://www.justinmklam.com/posts/2026/02/beginners-guide-split-keyboards/">A Beginner&#8217;s Guide to Split Keyboards</a> article, I want to do the following:</p><ul><li><p><strong>Get a simple row-staggered split keyboard:</strong> This matches my idea validation setup most closely. My goal is to be very productive from day 0. I am getting a <a href="https://keychron.de/products/keychron-q11-qmk-custom-mechanical-keyboard?variant=44759067754633">Keychron Q11</a>. It hasn&#8217;t arrived yet, but I am excited and a little worried as it is a high-profile keyboard, and for years now I am used to low-profile keys and slim keyboards.</p></li><li><p><strong>Research a simple column-staggered split keyboard:</strong> My initial research (and trying it out at the meetup) points to the <a href="https://typeractive.xyz/pages/build#lily58_choc">Lily58</a> as a good starting keyboard. I almost had it second-hand before another buyer beat me to it (darn it).</p></li><li><p><strong>Prototype with cardboard:</strong> For research, I am using the <a href="https://jhelvy.shinyapps.io/splitkbcompare/">splitkbcompare</a> app and cardboard boxes to play around (very early days).</p></li><li><p><strong>Consider a build:</strong> I might also try building something like a <a href="https://github.com/tompi/cheapino">Cheapino</a> or <a href="https://www.reddit.com/r/ErgoMechKeyboards/comments/1dacih5/cheapest_dirtiest_way_to_test_out_split/">some other idea</a>.</p></li></ul><h2>Falling into the rabbit hole</h2><p>Here are some resources:</p><p><strong>Concepts &amp; Guides</strong></p><ul><li><p><a href="https://www.justinmklam.com/posts/2026/02/beginners-guide-split-keyboards/">A Beginner&#8217;s Guide to Split Keyboards</a> &#8594; this is an absolute gem of a blog post to read about different types of keyboards, switches and keys, how to make a decision, what to look for etc.</p></li><li><p>Other useful glossary / terminology links</p><ul><li><p><a href="https://docs.keebd.com/information/keyboard-layouts/">Layouts</a></p></li><li><p><a href="https://docs.keebd.com/information/mechanical-switches/">Mechanical switches</a></p></li><li><p><a href="https://docs.keebd.com/information/gateron-switches/">Gateron switches</a></p></li></ul></li><li><p>This is also a great resource to see what&#8217;s available out there in one place <a href="https://github.com/diimdeep/awesome-split-keyboards">awesome-split-keyboards</a></p></li></ul><p><strong>Communities &amp; Events</strong></p><ul><li><p>I got lucky here, I asked a friend who &#8216;knows tech stuff, especially devices&#8217; that I am getting into the deep end of mechanical keyboards and voil&#224;, he hosts <a href="https://luma.com/hgwfl3pm">this meetup</a> (I didn&#8217;t know) and the next scheduled event was 3 days later. The cue here is to find a meetup / event around you, maybe something exists?</p><ul><li><p>This meetup was good for 2 reasons:</p><ul><li><p>I could validate my terminology understanding as I could hold conversations</p></li><li><p>A lot of folks brought their keyboards that were laid on the table to try / get a feel for switches etc.</p></li></ul></li></ul></li><li><p>Then there is this <a href="https://www.reddit.com/r/ErgoMechKeyboards/wiki/resources/">/r/ErgoMechKeyboards</a> community</p></li></ul><p><strong>Inspiration (Videos)</strong></p><ul><li><p><a href="https://www.youtube.com/watch?v=unMXQTSQEak">34 keys is all you need: an ergonomic keyboard journey</a></p><ul><li><p>Sounds crazy right? The answer to this is layers. Like when you hold shift, the lowercase letters become capital letters, that is a layer. In a keyboard with fewer keys, you have numpad on one layer, function keys on another layer (everyone maps their own, here is a <a href="https://ryan.himmelwright.net/post/building-34-key-layout/">concrete example</a> and here is <a href="https://github.com/nikbrunner/koyo">another one</a>). </p></li></ul></li><li><p><a href="https://www.youtube.com/watch?v=hjml-K-pV4E">How to Build a Handwired Keyboard</a></p></li></ul><h2>Closing</h2><p>I am really excited to get into the world of split keyboards and I hope that this post inspired you to do the same.</p><h2>Update</h2><ul><li><p>My Keychron Q11 arrived, took me about 3 hours to be productive and about a day or two to be more or less at the same typing speed as before. Love the key noise. Took me a while to get used to the higher profile keys but switching to something super low profile like the Apple&#8217;s magic keyboard (which I sometimes use when in a co-working space) is not an issue at all. </p></li></ul><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!xXLb!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!xXLb!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg 424w, https://substackcdn.com/image/fetch/$s_!xXLb!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg 848w, https://substackcdn.com/image/fetch/$s_!xXLb!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg 1272w, https://substackcdn.com/image/fetch/$s_!xXLb!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!xXLb!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg" width="1456" height="819" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:819,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:3877334,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/jpeg&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://blog.divyendusingh.com/i/193040918?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!xXLb!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg 424w, https://substackcdn.com/image/fetch/$s_!xXLb!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg 848w, https://substackcdn.com/image/fetch/$s_!xXLb!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg 1272w, https://substackcdn.com/image/fetch/$s_!xXLb!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F00c90ecc-8cf7-4393-b844-8422e668898f_8064x4536.jpeg 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p></p><p></p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Divyendu&#8217;s Notes is a reader-supported publication. To receive new posts and support my work, consider becoming a free or paid subscriber.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[My git-worktree workflow ft. worktrunk, caddy]]></title><description><![CDATA[Simple setup to boot a git-worktree with the right environment variables (via worktrunk) and dev server (via caddy)]]></description><link>https://blog.divyendusingh.com/p/my-git-worktree-workflow-ft-worktrunk</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/my-git-worktree-workflow-ft-worktrunk</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Sat, 14 Feb 2026 15:23:07 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Imagine you are building a large feature and find yourself deep in the context of a problem when you receive a request to solve a minor bug.</p><p>While you know how to fix this bug instantly, this is still a major context switch as you have to </p><ul><li><p>stash or temporarily commit your current changes</p></li><li><p>open a new branch</p></li><li><p>make the &#8220;minor&#8221; change</p></li><li><p>re-create the context</p></li></ul><p><a href="https://git-scm.com/docs/git-worktree">git-worktree</a> aims to address this issue by allowing you to work on multiple branches in the same repository.</p><p>However, it only provides the ability to quickly switch a branch without losing context. To have a working project where you can test changes end to end, you need some additional things like</p><ul><li><p>the environment variables, as the .env files are usually git ignored, they aren&#8217;t copied over in the git-worktree folder.</p></li><li><p>ability to run multiple versions of the codebase (if it is a web server for example)</p></li></ul><h2>Enter my setup</h2><h3>Worktrunk</h3><p><a href="https://nilan.substack.com/">A friend introduced</a> me to <a href="https://github.com/max-sixty/worktrunk">Worktrunk</a> the other day and I instantly loved it. Although, you can use git-worktree commands directly, worktrunk provides nicer APIs to achieve the same goals (copying .env files over, less typing). </p><p>It is a very thin wrapper, here is an example</p><pre><code>$ wt switch -c feat1
# gets translate to
# git worktree add -b feat ../repo.feat1 &amp;&amp; \
# cd ../repo.feat1</code></pre><p>See their docs for other examples but you get the idea. </p><h3>Copying .env files</h3><p>This is very project specific so it would vary from project to project but usually my projects are powered by .env files. You can run a git hook using <a href="https://lefthook.dev/">lefthook</a> to generate an env file (by getting the relevant secrets from 1password or locally encrypted env files using <a href="https://dotenvx.com/">dotenvx</a> for example). In fact, this is what I was doing until a week or so ago before I ran into worktrunk.</p><p>Worktrunk has a concept of <code>.worktreeinclude</code> file which is a <code>.gitignore</code> style file for copying files over, here is what it looks like for a web project that I work on</p><pre><code>$ cat .worktreeinclude
.env
.dev.vars</code></pre><p>Just this file is not enough, you need a way to run worktrunk hooks on each work tree, here is my config currently</p><pre><code>$ cat .config/wt.toml
[post-create]
install = "pnpm install"
env = "wt step copy-ignored"</code></pre><p>So essentially, when a git-worktree is created via <code>worktrunk</code>, we install the dependencies and copy over the .env files (yes this works for nested files too). With this, you are already ready to work on the project and run a dev server (but what about port clashes?). </p><h3>Clash of the dev servers</h3><p>You are usually testing things end to end in a web server, I usually like to even run projects with https on a custom URL. To power this, I use <a href="https://caddyserver.com/">caddy</a>, here is what my <code>Caddyfile</code> usually looks. </p><pre><code>$ cat Caddyfile
trackfootball.localhost {
  reverse_proxy localhost:5173
}</code></pre><p>But when using multiple git-worktrees, I didn&#8217;t want to stop the dev server so port 5173 (vite default) gets free. I wanted to create a predictable pattern so the next available port is used (and is addressable with https). </p><p>Luckily, <code>vite</code> does half the job of running the dev server at 5174, if 5173 is not available but depending on your application, you might have to get a random port and run your application there.</p><p>For the other half, I use caddy, here is the modified <code>Caddyfile</code></p><pre><code>$ cat Caddyfile                                                                                                                                   
:80 {
        @default host trackfootball.localhost
        reverse_proxy @default localhost:5173

        @port header_regexp port Host ^trackfootball-([0-9]+)\.localhost
        reverse_proxy @port localhost:{re.port.1}
}</code></pre><p>Essentially, this allows the following scheme to work</p><pre><code>trackfootball.localhost - localhost:5173 # hardcoded, existing setup keeps on working
trackfootball-5173.localhost - localhost:5173 # port derived from url
trackfootball-5174.localhost - localhost:5174 # port derived from url

# and so on...</code></pre><p>You might have to change some other things in your application for this to work for you or change the URL scheme to suit your application needs.</p><p>For example, this setup doesn&#8217;t support &#8216;login&#8217; locally for me because the cookie domain is set to <code>trackfootball.localhost</code>. But it doesn&#8217;t affect my local because of my local login setup (more on that later, I don&#8217;t really recommend that approach). I will likely change this to be <code>5173.trackfootball.localhost</code> in the future so the local login + cookies keep on working without any change. </p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Subscribe to Divyendu&#8217;s Notes</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><h3>Bonus - AI agents</h3><p>Is it 2026 without a post mentioning AI agents? While this post is 100% handwritten, you might have noticed by now that the above setup would make AI agents have access to isolated environment with git-worktree easily (depending on what all do you need to / want to isolate in your environment). </p><p>In fact, worktrunk supports running any binary command with a single command while creating the git-worktree. Here is how you would boot the <a href="https://ampcode.com/">amp</a> in one go:</p><pre><code>$ wt switch -c -x amp feat1</code></pre><h3>Bonus - local login</h3><p>I mentioned earlier in the post about why I am not bothered with local login auth cookie not working in my current setup, the reason is that I use an env var <code>UNSAFE_AUTH_BYPASS_USER</code> to completely bypass authentication locally (it is something I am experimenting with and don&#8217;t recommend it yet). In code it roughly looks like this:</p><pre><code>    ctx.user = null

    if (
      env.UNSAFE_AUTH_BYPASS_USER === '1' ||
      env.UNSAFE_AUTH_BYPASS_USER === 'true'
    ) {
      ctx.user = {
        id: 1,
        createdAt: new Date('2021-05-05T12:41:06.248Z'),
        updatedAt: new Date('2025-06-14T19:07:43.754Z'),
        email: 'john.doe@mail.com',
        firstName: 'John',
        lastName: 'Doe',
        locale: 'en',
        picture: 'https://i.pravatar.cc/150?u=jd@mail.com',
        auth0Sub: 'google-oauth2|104619003144932489723',
        emailVerified: true,
        type: 'ADMIN',
      } as User
      return
    }</code></pre><p>I did this to not having to deal with login flow and expiry locally (which I don&#8217;t recommend as it means that this code path will be less frequently hit). This also makes it easier for an AI agent to build features behind auth as it doesn&#8217;t have to struggle with authentication for each task.</p><h3>Conclusion</h3><p>This post described my current git-worktree setup, this hasn&#8217;t stood the test of time yet but I wanted to share it already to get feedback from the wider community. </p><p>Thanks for reading this and please share tips and your setup with me.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Subscribe to Divyendu&#8217;s Notes</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Leaving Twitter with Shamir’s Secret Sharing Scheme]]></title><description><![CDATA[In 2016, I removed all social networks permanently.]]></description><link>https://blog.divyendusingh.com/p/leaving-twitter-with-shamirs-secret</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/leaving-twitter-with-shamirs-secret</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Sat, 24 Jan 2026 11:18:34 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>In 2016, I removed all social networks permanently. Well almost all, except Twitter.</p><p>Now, it is time to get rid of Twitter as well. However, I am not ready to delete it fully yet. So, I devised a plan to block access for one year using Shamir&#8217;s Secret Sharing Scheme (SSSS).</p><p>In Harry Potter speak, Voldemort would have run:</p><pre><code>ssss-split -t 1 -n 7</code></pre><p>This means, there are 7 splits (of his soul) and any one of them keeps him immortal. </p><p>Here is my plan:</p><ol><li><p>Generate a password (passphrase variant) using <a href="https://bitwarden.com/password-generator/">Bitwarden Password Generator</a> and keep it in the clipboard. </p></li><li><p>Change Twitter password.</p></li><li><p><code>brew install ssss</code> (it is an implementation of <a href="https://en.wikipedia.org/wiki/Shamir%27s_secret_sharing">Shamir&#8217;s Secret Sharing Scheme</a>).</p></li><li><p><code>ssss-split -t 4 -n 7</code> to split the password into 7 chunks, 4 of which are needed to reconstruct it</p><ol><li><p>Use futureme dot org to send me 1 split in 1 year from now.</p></li><li><p>Use superpost dot com to send myself 1 split, this will be the only split that I would keep.</p></li><li><p>Give 1 split each to friends / family who won&#8217;t budge until the one-year period is over.</p></li><li><p>tl;dr Distribute the 7 splits such that getting 4 of them in a year should be safe enough.</p></li></ol></li><li><p>Test the password retrieval with <code>ssss-combine</code>, this ensures that everything is in order. Passphrase variant makes it easy to cross check.</p></li><li><p>Yeet the password from the clipboard.</p></li></ol><h2>Risks</h2><ul><li><p>I am unable to retrieve 4 splits when the time comes &#8594; that&#8217;s alright, not being able to access Twitter is something I can live with</p><ul><li><p>Though if this happens, I won&#8217;t be able to delete past posts &#8594; on the fence about that, but I do believe that the internet is written in ink, my current self is willing to live with this risk</p></li></ul></li><li><p>Someone gets access to my 4 secrets &#8594; not an issue, there is a 2FA layer in between</p></li><li><p>I can use password reset &#8594; to mitigate this, I change my email on a custom domain and transferred that over to a friend. My friend can of course reset the password (and <a href="https://help.x.com/en/forms/account-access/regain-access/2fa-problem">disabled 2FA</a> h/t <a href="http://captnemo.in">captnemo.in</a>) and therefore some level of trust is involved. </p></li></ul><h2>What&#8217;s next?</h2><p>I am not doing this because I spend a lot of time on socials (spoken like a true addict, eh?). I follow minimalism at both digital and physical levels and have no apps installed, I use socials from web versions which is much less addictive. I don&#8217;t spend a lot of time on social networks. But it does affect my attention, I do tend to get nerd sniped by cool things happening out there and end up losing time / attention as a second order effect.</p><p>Twitter has given me many friends and connections, the feeling of meeting an internet person in real life for the first time is always amazing.</p><p>However, over the recent years the general quality has dropped with the onset of politics and bots. In the past, posting 100 tweets might yield 10 meaningful connections. Now, it yields maybe 1 in 100 (or fewer).</p><p>I will replace Twitter and find better ways to connect with people in real life and will use this extra time and attention to practice cool things that interest me. Mostly that would be writing software, mathematics, football analytics and movies. Looking forward to diving deep into several topics with <a href="https://shugyokai.org/shugyo/what-is-shugyo/">Shugyo (&#20462;&#34892;)</a> in mind.</p><p>With this Twitter block my social network posture remains:</p><ul><li><p>Instagram - not a problem, it is a private account with like 27 followers, close friends and family.</p></li><li><p>LinkedIn - nothing changes, it is a professional network.</p></li><li><p>Twitter - blocked.</p></li><li><p>Bsky - exists, I don&#8217;t really use it, so don&#8217;t need to change anything.</p></li><li><p>HackerNews - not a problem, I sometimes submit Show HNs that don&#8217;t get a lot of traction.</p></li><li><p>I have no other social accounts.</p></li></ul><p>In an ideal world, I will be in a place where I can just delete Twitter once I am back next year.</p><p>I will continue to write on this blog, mostly long-form content. Feel free to subscribe and let&#8217;s stay in touch.</p>]]></content:encoded></item><item><title><![CDATA[Self-Hosting Photos]]></title><description><![CDATA[First rule of internet is same as the first rule of boxing first rule of boxing, &#8220;protect yourself at all times&#8221;.]]></description><link>https://blog.divyendusingh.com/p/self-hosting-photos</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/self-hosting-photos</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Mon, 21 Jul 2025 04:02:30 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>First rule of internet is same as the first rule of boxing first rule of boxing, &#8220;protect yourself at all times&#8221;.</p><p>In early 2023, I did a DNA test with 23andme. Of course, I made the rookie mistake of using my real name to create a profile. It might be too late for me but maybe this post helps others. </p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Divyendu&#8217;s Notes! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>Creating a fake name would have been totally viable (according to some Reddit posts). As I got the reports back and became more aware of the subject (and how DNA data can be abused), it felt &#8220;wrong&#8221; to store it on a cloud service (iCloud, I did enable end to end encryption, so there is hope).</p><p>This + watching too much sci-fi <a href="https://x.com/divyenduz/status/1636697474667626496">birthed the idea</a> of self-hosting everything including photos, media and files and having control of the email domain.</p><p>This year, the goal to move off Google and Apple photos was achieved. But first, let me talk about why I want to go off cloud for this (besides just privacy reasons)</p><p>I use an iPhone and Google Photos, so the pictures were getting synced to both clouds</p><ul><li><p>iCloud capacity was 200GB, Google&#8217;s capacity was 2TB - didn&#8217;t like this mismatch</p></li><li><p>Wasn&#8217;t sure if either / both these upload the full quality picture or pre-process them</p></li><li><p>Wasn&#8217;t sure about the relationship between the two clouds. Which one was the source of truth?</p></li><li><p>Privacy concerns (obviously)</p></li></ul><p><strong>Current setup - Synology Photos + Tailscale</strong></p><p>Hardware</p><ul><li><p> Synology DiskStation DS224+ 2 Bay Dekstop NAS</p></li><li><p>Seagate IronWolf 4TB Internal Hard Drive x 2</p></li></ul><p>Setup</p><ul><li><p>Synology Hybrid Raid SHR (3.6TB usable space)</p></li><li><p>Google Drive for backups (more later)</p></li></ul><p>While I didn&#8217;t purchase Synology NAS for Photos. It was meant for sensitive files like DNA data, identity document scans. In my research I quickly realized that synology photos has come a long way and can actually replace Google/Apple photos app. </p><p>The Synology Photos app offers a &#8220;backup&#8221; feature that downloads original quality pictures from Apple Photos and then you can optionally delete photos from Apple Photos. This is what I use but my &#8220;backup&#8221; is the &#8220;real&#8221; copy of my photos.</p><p>To access it on mobile devices, I use Tailscale and point the Synology Photos app to the Tailscale IP.</p><p>I could delete Google Photos. Apple Photos is not deletable (as the app is also the OS level API to move things around, duh) but I disabled photos sync to iCloud. </p><p><strong>Experience so far</strong></p><ul><li><p>Since I suddenly had much more storage space available. I started recording videos in Apple Log format and started taking photos in DNG (digital negative) format.</p></li><li><p>DNG / Log - this is still experimental, log needs to be processed and DNG needs to be converted to JPEG (possible in Synology) before posting to socials.</p></li><li><p>Tailscale makes accessing the library remotely easy BUT makes using a VPN hard. As iOS can only have one VPN at a time and I haven&#8217;t explored split DNS VPN on iOS yet (maybe it isn&#8217;t possible?). I can use Tailscale + Mullvad integration in dire situations.</p></li><li><p>Backups still go to Google Drive, but they are encrypted on the device.</p></li></ul><p>Ending this post with this security quote</p><blockquote><p>If something is on the network, assume that it is exposed.</p></blockquote><p>Hit me up if you have any questions about the setup.</p><p> </p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Divyendu&#8217;s Notes! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Making (Hard) Decisions Daily]]></title><description><![CDATA[Fast an decisive decision making is a fantastic skill to have at your disposal.]]></description><link>https://blog.divyendusingh.com/p/making-hard-decisions-daily</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/making-hard-decisions-daily</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Sun, 20 Jul 2025 02:57:33 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Fast an decisive decision making is a fantastic skill to have at your disposal. Fewer things hinder progress more than decision paralysis. </p><p>As they say, </p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Divyendu&#8217;s Notes! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><blockquote><p>&#8220;the opposite of excellence is mediocrity&#8221;</p></blockquote><p>I would like to add</p><blockquote><p>&#8220;the opposite of good decision is indecision&#8221;</p></blockquote><p>(and not a bad decision)<br></p><p>Most decisions are reversible, maybe not instantly but usually in 1-2 year time frame, usually less. Therefore, one must optimize for making &#8220;hard&#8221; decisions daily. Over time, the muscle builds and hard decisions get easier and slowly unlock more options for you.</p><p><strong>The Avoidance Problem</strong></p><p>Just making decisions is and getting better at them is not enough. You must also constantly put yourself in a position where you have to make decisions at a high cadence. This is where courage and or a system / framework to make choices that put you in front of decisions that you would otherwise avoid is important. </p><p>This post ended up being way more abstract than I originally intended it to be. I might revisit it but that&#8217;s all I have to offer for now. </p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Divyendu&#8217;s Notes! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Stuckness and the Path of Action]]></title><description><![CDATA[&#8220;Stuckness&#8221; is where the potential of maximum growth exists.]]></description><link>https://blog.divyendusingh.com/p/stuckness-and-the-path-of-action</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/stuckness-and-the-path-of-action</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Sun, 29 Jun 2025 12:52:20 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>&#8220;Stuckness&#8221; is where the potential of maximum growth exists. Yet the feeling itself is terrible and breaking out of &#8220;stuckness&#8221; is extremely hard. An enormous amount of productivity hacks and books have been written around breaking the &#8220;stuckness&#8221; walls. Over the last decade, I personally devised an &#8220;Abstract Productivity System&#8221; which is basically a system which encourages breaking tasks down so the </p><ol><li><p>next thing to work on is well defined</p></li><li><p>it is easier to recover from a slump by picking up the next thing</p></li></ol><p>Read that post here if you are curious. </p><div class="digest-post-embed" data-attrs="{&quot;nodeId&quot;:&quot;9f3176ac-21f4-4f47-b491-21f9d5be0c6e&quot;,&quot;caption&quot;:&quot;I have been writing about productivity for a while. It started with Trello in 2013 and turned into a very custom system of things to track in Notion by 2018. Currently, my day to day is driven by what I call \&quot;Yearly Process\&quot; that reveals itself in chunks of \&quot;Weekly plans\&quot;. I have had the though of productizing the process from notion into an app (mainly&#8230;&quot;,&quot;cta&quot;:&quot;Read full story&quot;,&quot;showBylines&quot;:true,&quot;size&quot;:&quot;lg&quot;,&quot;isEditorNode&quot;:true,&quot;title&quot;:&quot;Abstract Productivity System&quot;,&quot;publishedBylines&quot;:[{&quot;id&quot;:3465356,&quot;name&quot;:&quot;Divyendu Singh&quot;,&quot;bio&quot;:&quot;On Longevity, Life, Technology&quot;,&quot;photo_url&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/f1cfab76-ba4c-45fe-a4aa-e902813c94fa_1536x1920.jpeg&quot;,&quot;is_guest&quot;:false,&quot;bestseller_tier&quot;:null}],&quot;post_date&quot;:&quot;2025-04-12T07:24:52.604Z&quot;,&quot;cover_image&quot;:null,&quot;cover_image_alt&quot;:null,&quot;canonical_url&quot;:&quot;https://blog.divyendusingh.com/p/abstract-productivity-system&quot;,&quot;section_name&quot;:null,&quot;video_upload_id&quot;:null,&quot;id&quot;:161162592,&quot;type&quot;:&quot;newsletter&quot;,&quot;reaction_count&quot;:0,&quot;comment_count&quot;:0,&quot;publication_id&quot;:null,&quot;publication_name&quot;:&quot;Divyendu&#8217;s Notes&quot;,&quot;publication_logo_url&quot;:&quot;https://substackcdn.com/image/fetch/$s_!_iCs!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png&quot;,&quot;belowTheFold&quot;:false,&quot;youtube_url&quot;:null,&quot;show_links&quot;:null,&quot;feed_url&quot;:null}"></div><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Divyendu&#8217;s Notes! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><div><hr></div><p>But can we summarize &#8220;stuckness&#8221; and all the possible solutions (distilling all the bodies of work on productivity) in one go?</p><p>&#8220;Stuckness&#8221; is this uneasy feeling when you are tasked with something that you ought not to be doing or it is at a hardness level that is unpleasant for you and your whole body-mind system wants to avoid that and it is pretty good at distracting you. This is where easier work that gives you a feeling of progress like <a href="https://blog.divyendusingh.com/p/words">microblogging</a> or doom-scrolling kicks in. </p><p>The solution almost always is &#8220;act and do something&#8221;, do the next step, the smallest thing that you can do to move in the problem space where you are stuck. Most productivity systems encourage this one thing</p><ul><li><p>GTD (getting things done) encourages you to take up the micro-dopamine or distracting tasks in one go and build a pipeline for the rest</p></li><li><p>The one thing encourages you to take up one thing at a time (which should be the topic of your &#8220;stuckness&#8221;)</p></li><li><p>Eat the Frog encourages you to take up the hardest thing first thing in the morning. That&#8217;s usually the thing you are stuck at or has the potential for getting stuck at.</p></li></ul><p>Once you read enough self help books and try enough productivity solutions &#8212; you realize that almost all of them are true (or none of them are true depending on your perspective). If you are able to follow any of the productivity systems for long enough (let&#8217;s say 1+ year), you will likely be in the top 1% percentile of productivity.</p><p>Some folks might want to point out that real life is different and instead of a &#8220;single stuckness&#8221; there is &#8220;nested stuckness&#8221; (things blocked on one another) and &#8220;parallel stuckness&#8221; (multiple priorities that are actually equal). This is true and I believe that&#8217;s where many people fail to stick to the plan because eventually things get so overwhelming that you think that the productivity system you employed is not working. That&#8217;s why mentally linking &#8220;action&#8221; as a solution to &#8220;stuckness&#8221; is so important.</p><p>To summarize, make &#8220;action&#8221; the default. Action is the solution to &#8220;stuckness&#8221;. Practice this thought so many times that it becomes the default reaction. That&#8217;s where the real growth will start to happen.</p><p>When in doubt do something, do anything, just act.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Divyendu&#8217;s Notes! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Physical Goods as a Ceiling for Digital Media]]></title><description><![CDATA[Minimalism is hard.]]></description><link>https://blog.divyendusingh.com/p/physical-goods-as-a-ceiling-for-digital</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/physical-goods-as-a-ceiling-for-digital</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Sat, 28 Jun 2025 07:10:17 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Minimalism is hard. The modern (since 50s others tell me, I can only vouch for after 2000s) marketing shows possessions as a proxy for prosperity. There is some truth to it as social beings in the past &#8220;some&#8221; valuable possessions gave you a clout among your peers as someone who is trustworthy, reliable and can get stuff done. However with modern money and mass production economy that &#8220;some&#8221; seems to have a very high ceiling. </p><p>Doing minimalism with physical good is still easier than doing minimalism with digital goods. You see the things, can touch them, stack them up and give them away. </p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Divyendu&#8217;s Notes! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>With digital good usually being a file or just a database entry the ceiling almost becomes infinite. I remember from early 2000s when phone photography was starting to pick up. My father was losing his love for his hobby of photography. When I asked him why, he answered (paraphrased) &#8220;in the world of SLR cameras, every shot had a cost of being filmed on a physical photo roll and that made each picture more valuable and precious&#8221;. </p><p>With the prevalence of free photos, we end up taking many more pictures than before but fewer ever make it to a family photo album (if the concept lives on at all). </p><p>But anyways, personally, I have always been good at physical minimalism (Maybe even too good, once a friend visited me and force ordered some stuff on my amazon that he deemed as life necessities. I am grateful to having such friends). A &#8220;trick&#8221; that I have been using to manage minimalism in the digital realm has been to try and have a physical copy of a digital item that should be on my mind. </p><p>Example, all books, movies I have have a physical &#8220;mirror&#8221; (sounds unintuitive in minimalism land but provides a ceiling where none exists). I don&#8217;t delete older books but just put them in a cold storage that aren&#8217;t accessible. That means the stuff on &#8220;top of my mind&#8221; in digital world gets capped. This doesn&#8217;t apply to all the books, I might read a book in digital if I have decided to read something but keep a physical copy if I plan to re-read the book. </p><p>I do something similar with movies (I self host all the movies since last month, no more streaming services as the fragmentation in the industry meant loss of value, unlike spotify which seems to have won the music wars) and PS5 games.</p><p>Overall, minimalism brings clarity to me and some logistics are justified. </p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading Divyendu&#8217;s Notes! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Words]]></title><description><![CDATA[Writing is liberating.]]></description><link>https://blog.divyendusingh.com/p/words</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/words</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Fri, 27 Jun 2025 13:12:53 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Writing is liberating. It enables critical thinking and provides clarity. Anyone who as written sufficient amount of text understands that you don&#8217;t just write the thoughts you have but thought and the text inform each other and the evolution leads to clarity (or understanding that you need more familiarity/experience with a topic).</p><p>Microblogging (like Twitter) is pretty interesting. The limits of 240 characters (previously even 140) has a huge advantages like that it forces you to be terse and deliver condensed idea in a concise form (which I am sure seasoned writers benefit from and love) and it reduces the bar to entry (Tweeting is much easier than writing a full blown blog post).</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Divyendu&#8217;s Notes is a reader-supported publication. To receive new posts and support my work, consider becoming a free or paid subscriber.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>The downsides of modern social network economics encourage a lot of live status updates (shit posting etc.). I believe on the long run that is detrimental to craft of writing on the long run. Further &#8220;stream of consciousness&#8221; writing has advantages like feeling expressed yet to be a good writer, you need to do what mastering any craft takes, which is to write more and more and some more.</p><p>Microblogging satisfies the dopamine needs and the &#8220;need to write&#8221; might suffer in some people, specially those who started the craft of writing with microblogging platforms. </p><p>Some of this might not apply to everyone and that&#8217;s okay but I am sure it does apply to a lot of folks and with this piece of text. I wanted to raise awareness on the topic. </p><p>Going forward, I will refrain a lot of posting &#8220;status updates&#8221; type of posts on Twitter and resort more to long form / blog like texts.</p><p>After all, it aligns with a very strong personal value I have. I value &#8220;attention&#8221; a lot (maybe it is even the most valuable thing we have) for both myself and you. </p><p>Until next time.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://blog.divyendusingh.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Divyendu&#8217;s Notes is a reader-supported publication. To receive new posts and support my work, consider becoming a free or paid subscriber.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Abstract Productivity System]]></title><description><![CDATA[I have been writing about productivity for a while.]]></description><link>https://blog.divyendusingh.com/p/abstract-productivity-system</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/abstract-productivity-system</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Sat, 12 Apr 2025 07:24:52 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!_iCs!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3bfe3b6-085b-4429-beef-884ae77c0562_400x400.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>I have been writing about productivity for a while. It started with Trello in 2013 and turned into a very custom system of things to track in Notion by 2018. Currently, my day to day is driven by what I call "Yearly Process" that reveals itself in chunks of "Weekly plans". I have had the though of productizing the process from notion into an app (mainly for myself). While thinking about it though, I realized that a productivity process is very tailored to a person and that's why there are so many different apps and systems out there. </p><p>In this post, I would like to deliberate on some properties of an abstract productivity system using which as a base, one can form a system that works for them. </p><p>It boils down to the following:</p><p>1. A productivity system should help you to make progress during "bad" days.</p><p>2. A productivity system should increase your trust in yourself. </p><p>Let's dive deep into each of these</p><h2>Progress</h2><p>Life happens, you could be having the most productive time of your life, only for the streak to be broken by unexpected (or expected) travel. Or you could be sick. A productivity system shouldn't make you feel guilty during these times of unavailability, neither are you expected to be productive when you should be enjoying or recovering. </p><p>Getting back to momentum once you are available again should be enabled by your fancy task list. Which means it should have bite sized tasks waiting for you to take take up and well defined themes of what to do.</p><p>If you are curious like me, you need a list of things you won't do or do next year. Always protect yourself from being nerd-sniped.</p><h2>Trust</h2><p>I didn't make this connection between trusting yourself and productivity systems for a while. In the beginning, I was making the rookie mistake of being too ambitious, only to fall short on goals. </p><p>Only when I started aiming for the "next step that I can take" in a bigger goal and capped the ambition to meet myself where I am, I made this connection of trust. I went from the usual over ambition stressful goal system to "I am someone who achieves 100% of his goals". </p><p>Of course, this only works if you are honest and don't make the goals too easy. Learning / growth should feel hard like a good workout but never hurt / injure you. The productivity equivalent is that you are stopped in your tracks and stop relying on a plan.</p><h2>Other Tips</h2><p><strong>Immutable</strong> - Make the system immutable, it is okay to drop goals / change plans but when you do, write a note that you did that. That would help you with honestly finding your capacity and retrospective review, so you can plan better in future.</p><p><strong>Administrative tasks</strong> - If you are like me an find doing taxes and other admin tasks super tedious. Just keep mental bandwidth that 20% of your time WILL go into doing administrative tasks. Just doing the mental space separation adds to expectation-reality matrix and helps put them on the list and therefore getting them done (you are the person who achieves all of your goals remember <em>wink wink</em>).</p>]]></content:encoded></item><item><title><![CDATA[Auto Update Cursor on Linux]]></title><description><![CDATA[If you are using Cursor with .AppImage format, you would have noticed that the auto updater doesn&#8217;t work.]]></description><link>https://blog.divyendusingh.com/p/auto-update-cursor-on-linux</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/auto-update-cursor-on-linux</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Sat, 12 Apr 2025 06:45:28 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/e3c04886-dcb4-4a0b-98cb-629657cc5d68_1206x581.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>If you are using Cursor with .AppImage format, you would have noticed that the auto updater doesn&#8217;t work. Here is how you can fix it</p><ol><li><p>Write an update script: symlinks are needed to work around updating a running instance of cursor</p><pre><code>$ cat ~/Documents/software/cursor/update.sh 
#!/bin/bash

APPDIR="/opt/cursor"
SYMLINK="$APPDIR/cursor.AppImage"
TIMESTAMP=$(date +"%Y%m%d%H%M%S")

# Fetch the latest download URL from the Cursor API
APPIMAGE_URL=$(curl -s 'https://www.cursor.com/api/download?platform=linux-x64&amp;releaseTrack=latest' | jq -r '.downloadUrl')

# Validate that we got a URL
if [[ -z "$APPIMAGE_URL" || "$APPIMAGE_URL" == "null" ]]; then
    echo "Failed to fetch download URL from Cursor API"
    exit 1
fi

# Download to a versioned filename
NEW_APPIMAGE="$APPDIR/cursor.AppImage.$TIMESTAMP"
mkdir -p "$APPDIR"
wget -O "$NEW_APPIMAGE" "$APPIMAGE_URL"
chmod +x "$NEW_APPIMAGE"

# Update the symlink to point to the new version
ln -sfn "$NEW_APPIMAGE" "$SYMLINK"

# Optionally, clean up older versions (keep last 3)
ls -tp "$APPDIR"/cursor.AppImage.* | grep -v '/$' | tail -n +4 | xargs -r rm --

echo "Cursor updated successfully: $NEW_APPIMAGE"</code></pre></li><li><p>Make an update systemd service</p><pre><code>$ cat /etc/systemd/system/cursor-update.service 
[Unit]
Description=Update Cursor

[Service]
ExecStart=/home/d/software/cursor/update.sh
Type=oneshot</code></pre></li><li><p>Run it on a schedule</p><pre><code>$ cat /etc/systemd/system/cursor-update.timer 
[Unit]
Description=Run Update Cursor every 6 hours

[Timer]
OnBootSec=5min
OnUnitActiveSec=6h
Persistent=true

[Install]
WantedBy=timers.target</code></pre></li></ol>]]></content:encoded></item><item><title><![CDATA[Recurse Center - Return Statement]]></title><description><![CDATA[The Recurse Center is a self directed programming retreat.]]></description><link>https://blog.divyendusingh.com/p/recurse-center-return-statement</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/recurse-center-return-statement</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Tue, 14 May 2024 09:13:57 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!Ffz_!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The <a href="https://www.recurse.com/">Recurse Center</a> is a self directed programming retreat. I did the W1'23 batch (30th October 2023 to 9th February 2024). This batch was a bit special vs other batches because there was a break in between from 8th December 2023 to 2nd January 2024 during which I travelled to Japan. </p><p>Here is my experience from the batch</p><h2>The Planning</h2><p>I knew about RC from about 2017, when I met someone who was attending a batch in Bangalore. I wanted to do a batch since then and the original idea was to find time in life to do it in person from NY. Fast forward to late 2022, when I was planning for the year 2023. I thought that I would do a batch in 2023 but RC wasn't yet open to in-person, so I planned my batch remotely. </p><p>I just planned it way too early (as RC ended up opening for in-person batches). By February 2023, I knew that I would do this batch at the end of the year. Yes, if that sounds too early and too far ahead, it is true. For the last 2-3 years, I plan my yearly goals ahead of time and I chose this time for an RC batch because</p><ol><li><p>it is easier to take vacations around Christmas (I originally planned to take time off and do a half-batch but by the end of the year I ended up leaving my job to do a full-batch)</p></li><li><p>winters in Berlin is brutal, I thought it would be a great time to do the RC batch and add a kind, social programming community to dark winter times</p></li></ol><h2>The Experience - First Half</h2><p>I quit my job in September, so I roughly had 1 month before my batch started and I was simply tinkering and having fun building <a href="https://github.com/divyenduz/zoid-fs">zoid-fs</a>. When my batch started, it was a wonderful experience from the beginning, I met a lot of kind and curious programmers working on the edge of their abilities. Since, I had some momentum with my project, it acted as an anchor and protected me from the overwhelm of multiple streams of things happening at RC, there are always many different tracks of things happening at RC and FOMO can be real.</p><p>Timezone wise, I was in Europe, so I had the following setup, I would start working a bit late (I was mostly playing Football in the morning), like 10am-11am and work on my projects till 5pm. Then the US folks are available, so I was using the evenings mostly to pair program, attend events and do coffee chats. This worked really well for me. </p><p>With zoid-fs, I originally wanted to build a CRDT aware file system, so you can mount, say Obsidian on this file-system and it auto syncs across machines and there is never a collision. Though while working on the project, I diverted my attention to making it as much POSIX compliant (by running it against a POSIX <a href="https://github.com/tuxera/pjd-fstest">test suite</a>) and performant as possible. That meant that my data structures (chunked binary per file) is not the best suited for CRDTs and that was okay. It can support various backends and I would in future write a non-efficient (text only files, one DB column / file) backend that supports CRDTs. </p><p>However, I was able to do some cool things with this file system, like</p><ol><li><p>Making <a href="https://twitter.com/divyenduz/status/1714327120762048979">SQLite in SQLite</a> work</p></li><li><p><a href="https://twitter.com/divyenduz/status/1730184618739933258">Automatic document sorting</a> with LLMs</p></li><li><p>Making it a <a href="https://twitter.com/divyenduz/status/1712769548389065079">distributed FS</a> by simply mounting it on Turso</p></li><li><p>(incomplete) Making <a href="https://twitter.com/divyenduz/status/1719372700135678407">PostgreSQL createdb</a> work in this FS, so PostgreSQL in SQLite</p></li></ol><p>I also wanted to make a "always" compressed filesystem which led me to the rabbit-hole of my second big project in RC. I started the compression bits and got curious about how does compression **really** work, that led to me building <a href="https://github.com/divyenduz/zoid-zip">zoid-zip</a>. It is super slow but it does compress and decompress text files and it led me to appreciation for the field of data compression and information theory. I read further a lot about how to make this faster / production ready but didn't pursue to programming those as I wanted to move on to some other things. </p><p>It was also during this project that I learned a lot about bit manipulation and ArrayBuffers in JavaScript. In this project, I do all the necessary bit manipulation without using bitwise operators but getting a DataView in which bits are always available in an array, see <a href="https://github.com/o0101/Uint1Array">Uint1Array</a>. I think this is different from any other programming language and pretty cool. </p><p>All of this has happened and not even the first half of the batch is over, so of course I felt super productive. Besides, I used the "coffee chat" feature of RC and was meeting new people every day. This was a very fulfilling period of my life. </p><p>At this point, I spontaneously decided to tackle a project that I always wanted to do. I got into computers and programming because I used to play game boy games in a GBA emulator roughly when I was around 10-11 years old. I was always fascinated by emulation and decided to take a stab at it. This led to <a href="https://github.com/divyenduz/zoid-boy">zoid-boy</a>. I still had ~10 days left in the first half of my batch and I didn't want my RC time to become just about this project, so I time-boxed it. I wanted to build as much of the emulator that I can in these 10 days and then abandon the project. When I started, I was relatively confident that I would be able to reach at least a single pixel on screen stage (that didn't happen). I also didn't want to boringly type all instructions, so I wrote a small parser + code-generator that generates the CPU based on the assembly instruction mnemonic. Then, I went through <a href="https://realboyemulator.wordpress.com/2013/01/03/a-look-at-the-game-boy-bootstrap-let-the-fun-begin/">this blog</a>. It goes instruction by instruction and shows the state of the CPU and I just matched the state with the state of my generated CPU. With this workflow, I was able to get the boot rom to a success state and that was the end of this project. </p><h2>The Break</h2><p>During the mid-batch break, I travelled to Japan and didn't even carry my main laptop with me. This was my second trip to Japan in 2023 and again one of the best trips of my life but I won't digress too much in this post</p><ul><li><p><a href="https://twitter.com/divyenduz/status/1643627334006718466">March 2023 Trip</a></p><ul><li><p><a href="https://twitter.com/divyenduz/status/1641694451012866050">Mt. Fuji</a></p></li><li><p><a href="https://twitter.com/divyenduz/status/1642170832926707712">Osaka Castle</a></p></li></ul></li><li><p><a href="https://twitter.com/divyenduz/status/1742203827993079892">December 2023 Trip</a></p></li></ul><h2>The Experience - Second Half</h2><p>Unlike the momentum of the first half, my second half at RC started a bit slow. The batch resumed on 3rd January 2024 but I was set to return to Berlin on 9th January 2024. So there was a small overlap of travel i.e. unproductive time. Besides, I wasn't sure yet what would I do in the second half of the batch.</p><p>Was doing a bunch of reading/side quests (mentioned in the next section) before the first "Impossible Day" of the second half. "Impossible Day" is an RC event where you attempt to do a project in 1-day that you feel is impossible (for you). I started a no-code website builder and that was the foundation of my second half at RC (and till now after my batch). </p><p>I wanted it to support custom domains and everything and have a simpler infrastructure/deployment setup. So, I played around with setting up SSL for user defined domains with Caddy and deployments with Kamal and was pleasantly surprised by how good these tools are. Then, I dived into the rabbit hole of CSS in depth and layout system to build such a no code system.</p><p>Learned a lot while building this and I am still working mainly on this in the last few months.</p><h2>Side Quests</h2><p>So far, I only wrote about the main projects that I worked on at RC. I also did this thing that I call "time-boxables" where I spend 1-2 day doing something like a small project or play around with something, here is a quick list of such things (not ordered)</p><p>- Trying to turn my primary dev environment to a <a href="https://blog.divyendusingh.com/p/reproducible-development-environment">NixOS VM</a>. Eventually, there was enough friction that I switched to using Ubuntu VM and now I am back to macOS. I started doing this because building FUSE filesystem experience was way better in Linux vs macOS</p><p>- Game of Life, believe it or not, in a pair programming workshop, I programmed game of life for the first time in my life. It was super fun. </p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Ffz_!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Ffz_!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif 424w, https://substackcdn.com/image/fetch/$s_!Ffz_!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif 848w, https://substackcdn.com/image/fetch/$s_!Ffz_!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif 1272w, https://substackcdn.com/image/fetch/$s_!Ffz_!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Ffz_!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif" width="430" height="312" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:312,&quot;width&quot;:430,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:180537,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/gif&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Ffz_!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif 424w, https://substackcdn.com/image/fetch/$s_!Ffz_!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif 848w, https://substackcdn.com/image/fetch/$s_!Ffz_!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif 1272w, https://substackcdn.com/image/fetch/$s_!Ffz_!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F7060aa4e-31ae-40f4-88ee-a5d3a8174b10_430x312.gif 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>- Attended nand2tetris, maptime, crafting interpreters, emulators and VMs group, cryptopals, sadservers for a while on and off</p><p>- LLM based cover letter generator (to practice doing automatic document sorting with LLM in the file system)</p><p>- Open sourced <a href="https://github.com/divyenduz/trackfootball.app">TrackFootball.app</a></p><p>- Had German B1 exam on 14th November, so smack in the middle of things. That worked out well, I passed</p><p>- Update CV for potentials jobs etc + some interviews. Also, landed some "dream roles" at the start of the RC batch, so it didn't work out. This was top tier learning experience though, I feel that saying no to a dream role is super hard and I felt like I levelled up in taking responsibility of my own life when I did that to continue RC + planned sabbatical</p><p>- Played around with Calcite, wanted to build an SQL layer on top of FoundationDB. This project is super interesting to me, it died because FoundationDB doesn't work on any ARM processor, so I couldn't get a workflow setup (yet)</p><p>- Picked up Effect.website and moved a bunch of small application to Effect. I am sure it will be big in the TypeScript ecosystem</p><p>- Wrote a TCP PostgreSQL proxy to hot-swap the user in the proxy. This meant I had to re-implement the secure authentication in PostgreSQL wire protocol</p><p>- <a href="https://twitter.com/divyenduz/status/1759917106743693580">Fakegres</a> - distributed PostgreSQL built with Raft backed by SQLite (technically this was after my RC batch)</p><h1>Closing Thoughts on RC and Advice</h1><p>If you are just going to start a batch or on the fence for doing a batch, this section is for you. Please take it with a grain of salt as everyone is different. What works for me might not work for you</p><p>Do regular checkins: in the first half of the batch, I did a written check-in almost every day so I felt more coherent, productive and the time felt slow. In the 2nd half of the batch, I did check-ins sporadically and it felt like that the time just flew by. I didn't do video check-ins though they are available for two reasons, one I prefer written over video more and two it happened at 5:30pm in the evening for me, when I was already wrapping up the coding part of my day</p><p>Avoid FOMO: A lot of stuff is happening at RC at any given time and while I had the anchor of my projects. I still felt a bit of FOMO when saying no to events. Luckily, RC has the policy of "never graduating", and these events keep on happening in various shapes across batches. So, you can always do something outside of your batch. I convinced myself of this perpetual availability to say to to more things</p><p><a href="https://www.recurse.com/self-directives">Self-directives</a>: RC self directives are super powerful and in one of the related workshops, someone mentioned "when in doubt, write code". This was a very powerful directive for me. It took away all the stuck-ness from things that I experienced as I was no longer bound to planning/doing things right.</p><p>People are awesome: RC is a very unique community of kind and curious programmers, my personal experience was better than expected. Not only it was fun to talk to folks doing their own curious projects, there was a lot of positive energy in seeing folks just follow they curiosity and working on things just for the fun of it. Some people ask me, if they can do whatever I did in RC without doing a batch since it is self directed, the answer is no because the people and the vibe make all the difference. When you are working on hard projects and are stuck, it is empowering to see other people share their journeys of pushing through their limits and at RC there are people from various expertise and background, so there is a big chance that you would get unblocked by someone in a pairing session. </p><p>Presentations: Presentations is also a great recurring event at RC, folks present all sorts of cool things that I didn't think were possible! </p><h2>The End</h2><p>My RC batch was a great and fulfilling experience for me and I will surely do another batch in the future. I am grateful to have shared with likeminded and curious people. If you have any questions regarding RC or are curious about any of my side projects, please don't hesitate to reach out <a href="https://twitter.com/divyenduz">on Twitter</a>.</p>]]></content:encoded></item><item><title><![CDATA[Basics of Diet and Weight Loss]]></title><description><![CDATA[101 of the math behind diet and losing (or gaining) weight]]></description><link>https://blog.divyendusingh.com/p/basics-of-diet-and-weight-loss</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/basics-of-diet-and-weight-loss</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Wed, 18 Oct 2023 11:25:06 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!FWFY!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Writing my mental model out loud, I am not an expert. If you are an expert and think that I have made a mistake, please reach out and correct me. </p><p>To lose 1kg, you approximately have to be in ~7700 calorie deficit. For simplicity and to be on the &#8220;safer&#8221; side, I will use 8000 calories = 1kg weight loss. TK source</p><p>Example numbers for my use case: </p><ul><li><p>Weight: 72kg</p></li><li><p>Body Fat Percentage: 24%</p></li><li><p>Lean Mass (weight - fat): 72 - 24% of 72 =  ~55kg<br>(note, this includes bones)</p></li><li><p>Basal Metabolic Rate: 55 * 30 = 1650 calories<br>(or resting energy or daily calorie intake to maintain the weight)</p></li><li><p>Active Energy (Daily Average for 1 Year) = 600 calories</p></li><li><p>Total Daily Energy = 1650 + 600 = 2250 calories</p></li><li><p>Weight Loss Goal: 0.5kg / week = deficit of ~570 calories / day</p></li><li><p>Calorie Budget per Day = 2250 - 570 = 1680 calories</p></li></ul><p>I was 78kg at the beginning of this year! Also documenting my experiments on Twitter: </p><p>Follow here: </p><p><a href="https://twitter.com/divyenduz/status/1609546345076883456">https://twitter.com/divyenduz/status/1609546345076883456</a></p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!FWFY!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!FWFY!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png 424w, https://substackcdn.com/image/fetch/$s_!FWFY!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png 848w, https://substackcdn.com/image/fetch/$s_!FWFY!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png 1272w, https://substackcdn.com/image/fetch/$s_!FWFY!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!FWFY!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png" width="452" height="347.39864864864865" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/a71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:910,&quot;width&quot;:1184,&quot;resizeWidth&quot;:452,&quot;bytes&quot;:313449,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!FWFY!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png 424w, https://substackcdn.com/image/fetch/$s_!FWFY!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png 848w, https://substackcdn.com/image/fetch/$s_!FWFY!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png 1272w, https://substackcdn.com/image/fetch/$s_!FWFY!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa71de29c-b3a5-46bf-b436-70d9e97895f9_1184x910.png 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption">Screenshot of the Twitter link</figcaption></figure></div><h2>Gotchas / Other Things / FAQ</h2><ol><li><p>To lose 0.5 kg (a sane speed) in a week, you need to lose around 4000 calories which is being in a deficit of ~570 calories per day.<br><br>Why sane speed? because if you do it too quickly, your body slows down the metabolic rate<br></p></li><li><p>Body fat percentage &#8594; mine is based on InBody scan, DEXA scan is more accurate. But if you have nothing available, there are crude methods available.<br></p></li><li><p>Why multiply lean body mass by 30 calories to calculate basal metabolic rate? It is based on the book exercised</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!AjFS!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!AjFS!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png 424w, https://substackcdn.com/image/fetch/$s_!AjFS!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png 848w, https://substackcdn.com/image/fetch/$s_!AjFS!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png 1272w, https://substackcdn.com/image/fetch/$s_!AjFS!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!AjFS!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png" width="1400" height="787" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:787,&quot;width&quot;:1400,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!AjFS!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png 424w, https://substackcdn.com/image/fetch/$s_!AjFS!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png 848w, https://substackcdn.com/image/fetch/$s_!AjFS!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png 1272w, https://substackcdn.com/image/fetch/$s_!AjFS!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F94c05948-7f9c-4c71-938c-72e9f286599f_1400x787.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption"></figcaption></figure></div></li><li><p>Calorie math goes like this<br>1g carb = 4 calories<br>1g protein = 4 calories<br>1g fat = 9 calories<br>1g alcohol = 7 calories (safe to treat it like fat) TK source<br></p></li><li><p>Glycemic index &#8594; some foods are broken down slower than others, make you feel more satiated. If you are more satiated, you eat less. Fat has a high glycemic index<br></p></li><li><p>balanced diet &#8594; don&#8217;t try to skip fat totally or be leaned towards one macro nutrient. <br><br>Besides macro nutrients, a balanced diet also helps with various micro nutrients that the body needs<br></p></li><li><p>Hard things about counting calories &#8594; food labels can be +/- 10% off, weighting everything is hard, not all food is calorie counted, hidden calories (like sauces etc.)<br></p></li><li><p>Hard things about resting energy &#8594; it changes, specially if you shift your diet drastically. Apple watch and many online tools calculate it incorrectly because they use non-lean mass (see point 2)</p></li></ol>]]></content:encoded></item><item><title><![CDATA[Reproducible Development Environment]]></title><description><![CDATA[Experiments with NixOS, OrgStack and Cursor]]></description><link>https://blog.divyendusingh.com/p/reproducible-development-environment</link><guid isPermaLink="false">https://blog.divyendusingh.com/p/reproducible-development-environment</guid><dc:creator><![CDATA[Divyendu Singh]]></dc:creator><pubDate>Mon, 16 Oct 2023 17:15:38 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!SgkI!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>I have been hacking on a FUSE filesystem recently and I realised that Linux (as opposed to macOS, which is my primary OS/development machine) is a much better development environment for such a project because</p><ol><li><p>Availability of tools like <code>strace</code></p></li><li><p>More documentation on the internet vs macOS</p></li><li><p><code>libfuse</code> is more stable in failure modes vs OSXFuse (which means when I did something bad Linux crashes more gracefully than macOS)</p></li></ol><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!SgkI!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!SgkI!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png 424w, https://substackcdn.com/image/fetch/$s_!SgkI!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png 848w, https://substackcdn.com/image/fetch/$s_!SgkI!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png 1272w, https://substackcdn.com/image/fetch/$s_!SgkI!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!SgkI!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png" width="568" height="351.25042589437817" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:726,&quot;width&quot;:1174,&quot;resizeWidth&quot;:568,&quot;bytes&quot;:173566,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!SgkI!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png 424w, https://substackcdn.com/image/fetch/$s_!SgkI!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png 848w, https://substackcdn.com/image/fetch/$s_!SgkI!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png 1272w, https://substackcdn.com/image/fetch/$s_!SgkI!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4f2398ef-9b92-4dee-a588-e889d07996b2_1174x726.png 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Tweet: <a href="https://twitter.com/divyenduz/status/1712769548389065079">https://twitter.com/divyenduz/status/1712769548389065079</a></p><p>Demo: <a href="https://www.loom.com/share/aef864889f3840c7af85551bd479fc83">https://www.loom.com/share/aef864889f3840c7af85551bd479fc83</a></p><p>To set up a Linux dev environment still using macOS as the main operating system, I was using a hosted linux server (SSDNodes.com) but the latency was too much, so I thought about doing a local Linux VM (NixOS) and SSH into it.</p><p>Note: this is not a tutorial, I have skimmed fast through the details of how I made things work. If something is unclear, please feel free to reach out.</p><h2>Goal</h2><p>Since I am new to NixOS, the goal is simple, make this FUSE project run smoothly. I don&#8217;t have to be a Nix expert today but it should also not come in my way once my happy development path is set up. I should be able to pick my NixOS battles.</p><p>Eventually, I would like to move all my development to this setup, so switching to a new laptop can be &#8220;ideally&#8220; one command.</p><p>Note that this is an experimental setup, I haven&#8217;t used it enough yet to comment on, if it is good or not. </p><p>Note my understanding of Nix is limited, this is almost the first time I &#8220;dove deep&#8221; into it. If I am doing something incorrectly, please let me know.</p><h2>How it Works</h2><p>For getting NixOS VM, I used <a href="https://orbstack.dev/">OrbStack</a>, this was the easiest part of the process. Going from nothing to a running NixOS VM took less than 5 minutes.</p><h3>Cursor + Remote-SSH</h3><p><strong>Cursor (VSCode&#8217;s fork) remote SSH</strong> was the first hurdle, two problems</p><ol><li><p>SSH credentials didn&#8217;t work, orb does some magic so, just <code>ssh orb</code> should work&#8482; and it does in Teminal but Cursor failed to resolve the orb URL. So, I had to use the <a href="https://docs.orbstack.dev/machines/ssh#connection-details">raw connection details</a> from OrbStack.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!lRf4!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!lRf4!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png 424w, https://substackcdn.com/image/fetch/$s_!lRf4!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png 848w, https://substackcdn.com/image/fetch/$s_!lRf4!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png 1272w, https://substackcdn.com/image/fetch/$s_!lRf4!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!lRf4!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png" width="1266" height="478" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/f5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:478,&quot;width&quot;:1266,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:78970,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!lRf4!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png 424w, https://substackcdn.com/image/fetch/$s_!lRf4!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png 848w, https://substackcdn.com/image/fetch/$s_!lRf4!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png 1272w, https://substackcdn.com/image/fetch/$s_!lRf4!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Ff5316256-cb0a-4561-ba54-6fe33149a38e_1266x478.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div></li><li><p><code>remote-ssh</code> didn&#8217;t work, in hindsight I know that is because NixOS + VSCode <a href="https://github.com/nix-community/nixos-vscode-server">need some work</a> to <a href="https://nixos.wiki/wiki/Visual_Studio_Code">play together</a>. Mainly, it doesn&#8217;t work because the <code>node</code> binary bundled with VSCode/Cursor doesn&#8217;t work in NixOS (different architectures). There are three ways to fix this</p><ol><li><p>Copy a working node in the <code>~/.cursor-server/bin/&lt;version&gt;</code> folder. We will get later to how can you install such a <code>node</code> version in NixOS. </p></li><li><p>Use <a href="https://github.com/divyenduz/nixos-cursor-server">nixos-cursor-server</a>, I made this as a fork of <a href="https://github.com/nix-community/nixos-vscode-server">nixos-vscode-server</a>, and to my surprise it worked! All I had to do was global rename<br><code>/s/vscode-server/cursor-server/g</code><br>in text and file names and rebuild <code>flake.nix</code> file with <br><code>nix flake update</code></p></li><li><p>Use <a href="https://github.com/Mic92/nix-ld">nix-ld</a>, it is a way to &#8220;Run unpatched dynamic binaries on NixOS&#8221;</p></li></ol></li></ol><p>This was enough (I tried them all, settled with b.) to make remote-SSH work, however the in-editor terminal is still not working, it fails with: </p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!4it9!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!4it9!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png 424w, https://substackcdn.com/image/fetch/$s_!4it9!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png 848w, https://substackcdn.com/image/fetch/$s_!4it9!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png 1272w, https://substackcdn.com/image/fetch/$s_!4it9!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!4it9!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png" width="888" height="214" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/1d021f43-390a-43d1-811d-4f6468e85523_888x214.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:214,&quot;width&quot;:888,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;Image&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="Image" title="Image" srcset="https://substackcdn.com/image/fetch/$s_!4it9!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png 424w, https://substackcdn.com/image/fetch/$s_!4it9!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png 848w, https://substackcdn.com/image/fetch/$s_!4it9!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png 1272w, https://substackcdn.com/image/fetch/$s_!4it9!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d021f43-390a-43d1-811d-4f6468e85523_888x214.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>Interestingly, it works in VSCode, just fails in terminal. I have a hunch about why this might be happening but in the interest of setting up the development environment further, I skipped this for now. I can always SSH with <code>iterm</code> and use <code>tmux</code> (which is also my normal development flow) </p><h3>libfuse (and dynamic library loading)</h3><p>FUSE bindings require libfuse to be installed on the machine, installing dependencies is easy enough in NixOS, for global dependencies (and CLIs), edit the configuration nix file</p><p><code>sudo vi /etc/nixos/configuration.nix</code></p><p>and run </p><p><code>sudo nixos-rebuild switch</code></p><p>Here is how the relevant part of my configuration.nix looks like:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!92xV!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!92xV!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png 424w, https://substackcdn.com/image/fetch/$s_!92xV!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png 848w, https://substackcdn.com/image/fetch/$s_!92xV!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png 1272w, https://substackcdn.com/image/fetch/$s_!92xV!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!92xV!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png" width="470" height="676.027397260274" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:1260,&quot;width&quot;:876,&quot;resizeWidth&quot;:470,&quot;bytes&quot;:757656,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!92xV!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png 424w, https://substackcdn.com/image/fetch/$s_!92xV!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png 848w, https://substackcdn.com/image/fetch/$s_!92xV!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png 1272w, https://substackcdn.com/image/fetch/$s_!92xV!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F13dacb4f-e331-4bd9-949f-620ea052e8f2_876x1260.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>My expectation was that, just doing this will both install fuse and make it available for bindings. It did install fuse but the binding command failed with </p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!yFFh!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!yFFh!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png 424w, https://substackcdn.com/image/fetch/$s_!yFFh!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png 848w, https://substackcdn.com/image/fetch/$s_!yFFh!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png 1272w, https://substackcdn.com/image/fetch/$s_!yFFh!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!yFFh!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png" width="1456" height="421" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/e8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:421,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:1524466,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!yFFh!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png 424w, https://substackcdn.com/image/fetch/$s_!yFFh!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png 848w, https://substackcdn.com/image/fetch/$s_!yFFh!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png 1272w, https://substackcdn.com/image/fetch/$s_!yFFh!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe8475264-e63d-4804-9d34-97c2fcb5fa6e_2712x784.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>As the error message suggests, it was unable to find libfuse. Linux has a way to find packages (they are expected to be in well known places) and there are hooks to load them from non-standard paths. </p><p>On NixOS, things are installed at <code>/nix/&lt;*&gt;</code> path instead of <code>/usr/lib</code> or <code>/lib</code> for example. I eventually fixed this properly (while building Prisma, further in the blog post) but at this moment, I did what the error message told me to do i.e. find libfuse and put that in <code>PKG_CONFIG_PATH</code></p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!qYUU!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!qYUU!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png 424w, https://substackcdn.com/image/fetch/$s_!qYUU!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png 848w, https://substackcdn.com/image/fetch/$s_!qYUU!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png 1272w, https://substackcdn.com/image/fetch/$s_!qYUU!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!qYUU!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png" width="1456" height="1002" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:1002,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:1507335,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!qYUU!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png 424w, https://substackcdn.com/image/fetch/$s_!qYUU!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png 848w, https://substackcdn.com/image/fetch/$s_!qYUU!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png 1272w, https://substackcdn.com/image/fetch/$s_!qYUU!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F49caee1b-37a4-4574-873b-add220e3ce72_1610x1108.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Then, put the first path (I am not sure why there are so many) in an env var like</p><p><code>PKG_CONFIG_PATH=&lt;path-to-folder-containing-fuse.pc&gt;:$PKG_CONFIG_PATH</code></p><p>I later realised that this is the &#8220;wrong&#8221; way to do it, and the proper (to the best of my knowledge, please correct me if I am wrong) way to do it is via <code>nix-shell</code> (idk, maybe flake is even better but I haven&#8217;t used them yet).</p><p>Anyways, setting this env var made &#8220;npm install&#8221; work which means <code>node-gyp</code> was able to find libfuse and everyone was happy. </p><h3>Prisma (more dynamic linking)</h3><p><a href="https://pris.ly/d/custom-engines">Prisma&#8217;s architecture</a> involves binaries that it downloads in the background.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!1RZo!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!1RZo!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png 424w, https://substackcdn.com/image/fetch/$s_!1RZo!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png 848w, https://substackcdn.com/image/fetch/$s_!1RZo!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png 1272w, https://substackcdn.com/image/fetch/$s_!1RZo!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!1RZo!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png" width="650" height="331" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:331,&quot;width&quot;:650,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:null,&quot;alt&quot;:&quot;Prisma engine&quot;,&quot;title&quot;:null,&quot;type&quot;:null,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="Prisma engine" title="Prisma engine" srcset="https://substackcdn.com/image/fetch/$s_!1RZo!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png 424w, https://substackcdn.com/image/fetch/$s_!1RZo!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png 848w, https://substackcdn.com/image/fetch/$s_!1RZo!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png 1272w, https://substackcdn.com/image/fetch/$s_!1RZo!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F11094c7f-2e1e-4bc1-a6fd-e5cdd783aaa9_650x331.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a><figcaption class="image-caption">Prisma&#8217;s architecture</figcaption></figure></div><p>The problem is that they don&#8217;t have precompiled binaries for NixOS. Probably not for the library or something (I am not sure if this is a bug or not) but this is what happens if I try to run </p><p><code>npx prisma version</code></p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!9wNM!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!9wNM!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png 424w, https://substackcdn.com/image/fetch/$s_!9wNM!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png 848w, https://substackcdn.com/image/fetch/$s_!9wNM!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png 1272w, https://substackcdn.com/image/fetch/$s_!9wNM!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!9wNM!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png" width="1456" height="286" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/e57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:286,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:1312831,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!9wNM!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png 424w, https://substackcdn.com/image/fetch/$s_!9wNM!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png 848w, https://substackcdn.com/image/fetch/$s_!9wNM!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png 1272w, https://substackcdn.com/image/fetch/$s_!9wNM!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe57a1559-2e53-4838-b32a-7a6ab9cebe41_2890x568.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>I know that you can compile + provide custom binary paths to Prisma CLI and that&#8217;s the path I took. That is cloning <a href="https://github.com/prisma/prisma-engines">prisma-engines</a> repo and running</p><p><code>cargo build --release</code></p><p>The problem, cargo expects some libs to be installed at available at standard paths, like openssl etc</p><p>The same solutions that were needed for libfuse + bindings were needed here, however, I read a bit more and realized a better way to do dynamic linking using <code>nix-shell</code></p><p><code>nix-shell</code> provides a temporary shell unique to the project (shell.nix file lives in the project). Using this file, you can easily populate env vars and otherwise the build environment for a project to work. Here is how my <code>shell.nix</code> file looks for prisma-engines repository</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!4bg9!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!4bg9!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png 424w, https://substackcdn.com/image/fetch/$s_!4bg9!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png 848w, https://substackcdn.com/image/fetch/$s_!4bg9!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png 1272w, https://substackcdn.com/image/fetch/$s_!4bg9!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!4bg9!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png" width="1456" height="732" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:732,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:877984,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!4bg9!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png 424w, https://substackcdn.com/image/fetch/$s_!4bg9!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png 848w, https://substackcdn.com/image/fetch/$s_!4bg9!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png 1272w, https://substackcdn.com/image/fetch/$s_!4bg9!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F20dae0c4-231b-4108-b67d-8e7fe36d4ccd_1640x824.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>(I think it is missing the &#8220;correct&#8221; way to link openssl, because I patched it the same way I did <code>libfuse</code>, using <code>OPENSSL_DIR</code> env var). For some binary dependencies, it is using <code>nix-ld</code>. </p><p>Proper way might be this: <a href="https://nixos.wiki/wiki/FAQ/I_installed_a_library_but_my_compiler_is_not_finding_it._Why%3F">NixOS + Libraries</a></p><p>Once <code>cargo build --release</code> worked, I had to make the correct env vars, to do that, I used shell.nix in the main project directory now with following contents</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!NLHT!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!NLHT!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png 424w, https://substackcdn.com/image/fetch/$s_!NLHT!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png 848w, https://substackcdn.com/image/fetch/$s_!NLHT!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png 1272w, https://substackcdn.com/image/fetch/$s_!NLHT!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!NLHT!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png" width="1456" height="526" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/d481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:526,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:1633861,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:null,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!NLHT!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png 424w, https://substackcdn.com/image/fetch/$s_!NLHT!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png 848w, https://substackcdn.com/image/fetch/$s_!NLHT!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png 1272w, https://substackcdn.com/image/fetch/$s_!NLHT!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd481f62f-10cc-4daf-869c-90e9729bf72d_2498x902.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Note: I had to rename the <code>libquery_engine.so</code> binary to <code>libquery_engine.node</code>, to make it work (I am not sure yet where this requirement comes from but only .node works)</p><h2>Summary</h2><p>This blog post and my setup is WIP (as you can see) but I am surprised with the amount of good documentation that NixOS has on various topics and I was able to get the thing to work. Overall, I hope to make this VM my primary development environment eventually and open source my configuration. </p>]]></content:encoded></item></channel></rss>