5 ms·
The three line single binary compiler free blog
- georgia_peach 5y agoLooks like it's harder to do a redbean in golang than it should be at the moment.
- rob74 5y agoTBF, implementing Redbean in C required 3000+ lines and several third party dependencies. Of course it's more full-featured than this Go "proof of concept", but still, I assume it would be much easier to implement Redbean in Go than in C - as you would expect from a much younger "batteries-included" language.
- georgia_peach 5y agoWasn't criticizing Go. It's the most Wirth-like language we have today with a vibrant ecosystem. Looking at their github, they're already on it.
- fivelessminutes 5y agoJust mount your zipfile using fuse and serve as normal. You can also produce and edit the zipfile that way. https://www.systutorials.com/docs/linux/man/1-fuse-zip/ https://www.systutorials.com/docs/linux/man/1-fuse-zip/
- georgia_peach 5y agoBut then you have two files and a mount to deploy instead of a single file. Ted was trying to do a redbean like jart did with APE. https://redbean.dev/ https://redbean.dev/ Which is an awesome concept that also reeks of re-purposed early '00s malware distribution trick.
- EdSchouten 5y agoWhat’s the requirement for having it all concatenated into a single file? What’s wrong with having the webserver binary and the ZIP file be separate?
- karmanyaahm 5y agoI think it's just an interesting technical challenge, not for practical purposes (other than sites that never update content maybe).
- deleted 5y ago[deleted]
- skybrian 5y agoIt seems like both problems in the Go standard library should be fixable? They are corner cases that could be made to work without breaking anyone.
- breadchris 5y agoi believe you can achieve what you want with embed https://pkg.go.dev/embed https://pkg.go.dev/embed
- ipython 5y agoThat’s not the same thing - with embed you have to recompile the server every time you change the page contents.
- cobbal 5y agoI see at least two compilers: zip and cat. :)
- Scaevolus 5y agoThis CL would fix Go to be able to read zip files concatenated to binaries: https://go-review.googlesource.com/c/go/+/387976/ https://go-review.googlesource.com/c/go/+/387976/
- FullyFunctional 5y ago"just because you noticed its misspelled" is either a very clever joke or a marvelous coincidence.