Live data from Hacker News

Show HN: Redbean – Single-file distributable web server

justine.lol

261–264 of 264 posts

Re: Show HN: Redbean – Single-file distributable web server

#261
post #10

I just spent 30 minutes reading about this. I'm so shocked that I'm logging in to comment after 5 years of lurking. Justine has built a c library that allows you compile a binary once and have it run it on any os or baremetal. The SAME binary. Quite frankly, that sentence doesn't even make sense to me. Check out https://storage.googleapis.com/justine/cosmopolitan/index.ht... As far as I'm concerned, this is literal m…

Could you please explain to someone from the web domain with very little experience with compiled C programs why this is significantly better than, say, distributing a python program? Python runs on all the platforms mentioned. Or alternatively requiring compilation from source?

The python script/program ultimately depends on a Python interpreter which currently has to be distributed as a different binary for every platform.

So in the end, the difference is purely where the platform-differentiated compilation happens for VM & interpreted languages like Java & Python.

This would instead allow you to ship a single Python executable that simply works everywhere. Whether with a bundled-in script/program, or just the interpreter.

Re: Show HN: Redbean – Single-file distributable web server

#262
post #239
post #10

I just spent 30 minutes reading about this. I'm so shocked that I'm logging in to comment after 5 years of lurking. Justine has built a c library that allows you compile a binary once and have it run it on any os or baremetal. The SAME binary. Quite frankly, that sentence doesn't even make sense to me. Check out https://storage.googleapis.com/justine/cosmopolitan/index.ht... As far as I'm concerned, this is literal m…

While this is absolutely amazing, and I'm still trying to see if I'm even able to grok the how.. But, the paranoid in me is now curious/afraid if this approach can/will lead to multi-OS malware?

That sort of malware already exists. This does simplify making it by a lot, because now it can much more easily ensure its portability without external communication.

Re: Show HN: Redbean – Single-file distributable web server

#263
post #59

Earlier quoted context omitted.

Appreciate the response. So it's a bigger win for C devs specifically. I am a C# dev so I am trying to understand what opportunities this project unlocks.

Why you have pigeonholed yourself? "X Dev" is so cliche. You can compile C# to x86 machine code - this project has less to do with C and more to do with PE format and syscall tables. It means that it's language agnostic but not standard library agnostic.

Completely agree. The program is written in C# -- you aren't! :-)

Re: Show HN: Redbean – Single-file distributable web server

#264

Earlier quoted context omitted.

This is too real. Except at this point, after 25 years I have probably ten of these.

I've been thinking of putting together github repo which is just an index out to people's snowflakes. If I do, I'll reach out.

Yes, please.
Post reply on HN