Hacker Newsnew | past | comments | ask | show | jobs | submit | mlysk's commentslogin

Part 2 of my blog series on running SQLite databases directly on Git storage.

This post explores how to use zlib's Z_FULL_FLUSH flag to enable random access in Git's compressed objects, making it possible to read subsets of large files without decompressing the entire object.

Prologue: https://blog.lysk.tech/sqlite-on-git-prologue Part 1: https://blog.lysk.tech/sqlite-on-git-part-1

Github repo: https://github.com/martin-lysk/talepack


I thought about forking the pwa - should be easy to add the same concept using https://developer.chrome.com/docs/capabilities/web-apis/file... but I didn't want to leave vscode


My goal is that it renders on GitHub as well as on my blog. GitHub doesn’t support css based dark mode afaik


Ah, you have a button for the toggle! Did you know that you can conform to the user's light/dark preference with CSS? Like this:

    :root { --varname: #FFE; }
    
    @media (prefers-color-scheme: dark) {
        :root { --varname: #022; }
    }
Edit: To expand on this, I dislike light/dark toggles. If I have dark mode on, seeing a bright screen and having to search for a toggle is jarring. Just show me the colours according to my preference!


How can you detect the system preferences in the browser?


I answered that in the comment you're replying to. If you want a more authoritative answer: https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/A...


Last I checked on this the workaround is embedding CSS inside an SVG, here's a demo: https://github.com/sindresorhus/css-in-readme-like-wat

I used this on a personal project to add a README logo that is dark mode friendly: https://paul.af/github-readme-dark-mode


Not what I needed - my concepts life in one excalidraw, containing multiple frames of interest like https://github.com/martin-lysk/martin-lysk/blob/main/blog/26.... The blogposts reference some of them like here: https://blog.lysk.tech/nfs3-event-side-channel


Thanks for the flowers


Author here: Haha - yeah that is kind of meta - i know. Other content will be more about the acutual problems i solve. Check out https://blog.lysk.tech/sqlite-on-git-prologue ;-)


Hey, I found that interesting and went looking for an RSS feed link on your site but couldn't find any. Assuming you don't have it already, do you plan to add it?


on it



That's an interesting article. I was being snarky, but I still think your article about Excalidraw images is still interesting.


Author here: I use mermaid lot as well and for some things like process flows, and to model interactions it it outrules excalidraw and posts will follow where i need exactly that. but to visualize things high level i find excalidraw way nicer.


Thanks for the hint - just updated the post and adde the attribution


Pretty new to hn, thanks for the hint


Author here - I plan to add the rest of the research in biweekly cycles


Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: