this post was submitted on 22 Jul 2024
13 points (100.0% liked)

unixporn

184 readers
1 users here now

*The FREE home for NIX customization! Submit screenshots of all your *NIX desktops, themes, and nifty configurations, or submit anything else that will make chatters happy. Maybe a server running on an RPi, or a MNT Reform signed by RMS? Show the world how free your computer can be!

founded 1 year ago
MODERATORS
13
submitted 1 month ago* (last edited 1 month ago) by mccd@lemmy.sdf.org to c/unixporn@lemmy.sdf.org
 

Hey everyone!

Recently managed to figure out my memory issues, had a corrupt ram that I needed to replace. Openbsd has now been running great and all the memory issues are gone.

I fell in love recently with dithered images, it creates an amazing aesthetic.

Setup:

OS - OpenBSD
Term - Xterm
Shell - sh
WM - cwm
Font - Go Mono
Applications - imv, vim, xclock

My vim theme is a slightly modified version of the default quiet theme. Just changed the background and comment color.

top 5 comments
sorted by: hot top controversial new old
[–] hydroptic@sopuli.xyz 2 points 1 month ago* (last edited 1 month ago) (1 children)

Good 'ol golang, intmax and containsSubstring (or containsNumber or containsValue etc etc) and so on in like 80% of the codebases because Rob Pike thinks copy-pasting code builds character. At least I gather things have gotten better with generics now, but I haven't used Go in a few years although I wrote it for a living starting from way before there was even package management (I remember when error was Error)

[–] mccd@lemmy.sdf.org 2 points 1 month ago* (last edited 1 month ago) (1 children)

Yeah I'm very new to the language; I like the simple toolchain and network libraries but the way I need to reimplement a bunch of primitive functions surprises me a lot (no math.Max for ints ??). I feel productive in Go, but a part of me feels that is just because I'm outputting so much boilerplate haha.

If I could have ocaml with the toolchain and library ecosystem of Go, I'd be happy.

[–] hydroptic@sopuli.xyz 2 points 1 month ago (1 children)

Yeah even though I spent a long time writing Go, I really can't say I like the language. Like you, I did feel productive in it, but holy fuck was there a lot of boilerplate. I'm really not a fan of the concurrency model either, the idea's good but the implementation makes it way clunkier than necessary because you get no handles to goroutines you spawn and you have to manually set up channels (which have a lot of nonobvious gotchas)

[–] mccd@lemmy.sdf.org 2 points 1 month ago* (last edited 1 month ago) (1 children)

My feeling for Go and why I went with it for my project is that I think it is the language that sucks the least for server development since I value simplicity, decent performance, fast feedback loop, portability, offline docs and good tooling. It also has a big userbase, and I have a bunch of obscure tooling elsewhere so I felt I didn't want to introduce more esoteric choices. But it felt a bit sad that it was the best option.

I also looked at Elixir but found the layers of abstractions a bit intimidating and I heard stories that compilation times becoming long.

Ocaml ticks most of the boxes of what I look for, but the library ecosystem is immature for server development IMO.

Do you have any language you prefer?

[–] hydroptic@sopuli.xyz 2 points 1 month ago

If I had to do a server-side project for money I'd probably pick Go again. I don't have to like the language to recognize it's a good tool for the job – I'd gripe about it, but I'd use it anyhow. Can't stand the server side Javascript ecosystem, the Java ecosystem (including Scala etc) is good but nowhere near as easy to deal with as Go's, Erlang / Elixir seems decent but it's a bit alien to me because I've not written anything in either beyond just hobby stuff to learn the languages and the concepts.

Pony is what I'd actually prefer using for work projects but it's so niche and its ecosystem isn't exactly vibrant that it wouldn't be a great choice. As a language it gets a ton of stuff right though, and I vastly prefer its memory safety model (reference capabilities) over what eg. Rust or Swift do, it's just much easier to reason with for me – although it's not an easy language to learn as such because the ref cap model does force you to think very differently about things. Its actor model is great too; the fact that it makes guarantees about message delivery order makes it a lot easier to reason with.