How to learn a new (programming) language

...by leveraging your existing knowledge to rebuild something you've already built. A Case study in Hare

(Cold open)

I watch a lot of “edutainment” on Youtube. And when a video on Portal 2 being turned into a webserver crossed my feed, I had to watch.

Combining that with this “webserver in 25 lines” from Computerphile I saw the previous year, I got inspired to write a webserver in Zsh.

Here’s the immediate result is what came out of that. Even though it’s single-threaded, it’s still reasonably scalable, since I’m poll()ing all open connections (using the Zsh builtin zselect).

And a toy webserver like this is a great project to take to a new language.

[Read More]
code  zsh  harelang  web 

.zshrc from scratch

My zsh shell files are at over 1500 lines of code, not including many plugins of various complexity. It’s a bit of a mess, but it’s all things that I wrote (or copied) for a reason.

But easily 90% of what I love about this shell is doable in less than 100 lines of code.

So let’s build a Zsh config from scratch!

[Read More]
zsh  config  linux 

Ironing Out the Wrinkles

So I just re-installed Arch EndeavourOS on both my laptop and desktop and decided it was time to do some much needed re-architecting. I also wanted to keep track of what changes I made in this post so I can maybe someday make an Ansible playbook to set these things up.

A few new things this time:

  • I’m starting from EOS KDE edition, switch to KDE utils
  • EndeavourOS installs firewalld, let’s learn to use it
  • Tailscale
[Read More]

Its Nice

It sucks when your laptop breaks. But it’s nice when you immediately know how to fix it.

Today that happened to my Arch laptop (either a grub config or kernel install problem.

All it took was:

[Read More]
linux  arch 

Thoughts on the Steam Deck

As a person who has been daily-driving Linux for about five years now, I am understandably excited for the upcoming Steam Deck and what it means for gaming on Linux in general. I just want to have some place to collect my thoughts so I could easily share what I thought of it.

[Read More]

De-Googling my OnePlus 5T with LineageOS

Privacy Matters

I am known among friends and family to be a privacy-concious person. My opinion on privacy matters is that you should be aware of what you are paying with your data, then make the decision that makes the most sense to you.

[Read More]