Better HN
topnewbestaskshowjobs
Log inSign up

metaist

3 karma · joined Jul 29, 2024 (2y ago) · 7 submissions

Submissions

1.

Trust, Delegation, and the Trap(metaist.com ↗)

3 points · by metaist · 10mo ago · discuss

comment 11mo ago · link · parent

Getting your code running cross-platform used to be really tough. Look at all the different architecture + OS combinations you have to support. Justine Tunney came up with Cosmopolitan libc which lets you compile code into a clever zip file that runs on Linux/MacOS/Windows with no changes.

aghamut published Superconfigure which compiled python (and many other tools) into a "Cosmopolitan Python" file which runs on all those same OSes. What's better is the repo contains a simple recipe for adding your own files to the zip. https://github.com/ahgamut/superconfigure#adding-to-the-zip-...

In 2024, I wrote a post about packaging python apps using Cosmopolitan Python: https://metaist.com/blog/2024/08/packaging-python-with-cosmo...

This morphed into a Cosmopolitan Python App that makes Cosmopolitan Python Apps: https://metaist.com/blog/2024/09/cosmofy-0.1.0.html

But it was very limited: it couldn't handle dependencies at all. So I decided to rewrite the whole thing around `uv` (which handles dependencies _very_ well).

Along the way, I learned how to emulate parts of the Python CLI from _within_ python: https://metaist.com/blog/2024/09/pythonoid.html

I also learned how to emulate uv's style (both in subcommand structure and colored output): https://metaist.com/blog/2025/12/emulating-astral-cli.html

And I learned when to limit emulation (in the name of good design) when trying to implement parts of `ls`: https://metaist.com/blog/2025/12/emulating-ls.html

There's a surprising number of moving parts, but I'd love to get feedback on what works / could be improved.

3.

Show HN: Cosmofy – bundle your Python code for Linux/Windows/MacOS(github.com ↗)

10 points · by metaist · 11mo ago · 1 comment

4.

Dependency Groups to the Rescue(metaist.com ↗)

1 points · by metaist · 12mo ago · discuss

comment 2y ago · link · parent

Strongly agree. Plus all the benefits of automated tools like dependabot. Wonder what it would take to get poetry, pdm, and rye to change their behavior.