Weeknotes 158
7th July, 2024
“Difficult job control”
-
Apparently I’ve been writing weeknotes every week for 3 years now! Maybe I can be consistent.
-
For any given problem, I never quite totally believe I’ll be able to solve it. If I start at a whiteboard, I have to think, so I have to be smart, and I’m not sure when I’ll be done thinking, so it’s really hard to start. Instead, I make a to-do list: an even simpler one, with a single dumb-as-rocks failing test that points vaguely in a direction of some sort, possibly the wrong one, who knows. I don’t have to be smart to make it pass, so I can just do it, so I do do it. This helps me spend less time not starting, and leaves me with much-needed momentum.
I could not relate to this more.
I hardly ever TDD because although I strongly believe in it as a practice, getting a test setup can often be more difficult than writing then actual production code. However, I should remember to attempt this more often.
-
The manager’s unbearable lack of endorphins
I’d feel competent, and valuable, and worthy and just good. It’s the best feeling.
This blog post made me realize that the vast majority of the time I feel nothing from what I do.
-
I spent a surprising amount of time trying to figure out how to populate a
jsonb
column fixture because various Rails versions seem to have changed the way it should be done 🤔For a nested JSON object you can specify the key/values in YAML like this:
translations: en-US: title: Title here
-
Julia Evans' Reasons to use your shell’s job control
I use
CTRL-z
andfg
a lot during my normal programming workflow for the same reasons as reason 3 in this article (running a command while using vim).This is despite me using
tmux
– which takes a tiny bit longer to switch between windows. I imagine I could achieve a better workflow if I had some sort of custom keybindings setup intmux
but I’ve always found it fairly inscrutable when it comes to configuration. -
Indenting output in a shell script with pr – Another day, another Unix utility I’ve never heard of.
-
This week at work was very difficult. I really need to figure out how to get things done without all the self-hatred. I felt like quitting and going to live in the woods.
-
Announcing the Ladybird Browser Initiative – a new web browser.
Chris Wanstrath, GitHub co-founder:
The world needs an independent, open source browser free of corporate interests.
Today @awesomekling and I are launching the Ladybird Browser Initiative, a nonprofit focused on @ladybirdbrowser, and my family is donating $1M.
Join us in supporting a browser that supports you!
Andreas Kling:
Ladybird uses a brand new engine based on web standards, without borrowing any code from other browsers. It started as a humble HTML viewer for the SerenityOS hobby project, but since then it’s grown into a full cross-platform browser project supporting Linux, macOS, and other Unix-like systems.
Hell of a task, this.
-
TIL about
.reflect_on_all_associations
which will return all associations defined on an ActiveRecord model. I’ve needed this before, and thought this must be new, but no, it has been in Rails for 20 years 😮(byebug) Foo.reflect_on_all_associations.map(&:name) [:client, :versions, :category, :related, :translations]
-
Bolognese is an exercise in restraint
-
I have finally booked my flights to Toronto in September ✅