2 min min read - November 16, 2020
(I use Mac, so whenever I mean Ctrl+Shift+F I do Cmd+Shift+F)
It would be great that each time we join some company, or project we always work on something we're familiar with, or we build everything from scratch. Often it's not the case. While working on a book describing our trade, I realised how much of work, in software engineering, we focus on maintaining the legacy, or unknown code. Sometimes in languages, I haven't dealt with or haven't used of ages. In brief, there is one technique that worked well. I call it "roll up the yarn".
What does it mean?
It may be a CSS class or element id in the frontend. It may be radio button value. In the worst scenario, it may be log entry or temporarily added code that throws an exception. Its role is to give me an anchor to start. From that moment, Ctrl+Shift+F is my friend. I search for that specific identifier in the whole code. If I need to find the project that uses it and my company uses GitHub, I can search for the term across the organisation. Go to your organisation page on GH and start typing in a search. The first autocomplete will suggest it.
Often we need to break to make. Once I found the code that seems related to what I want to achieve, I make a singular change and test. Some IDEs or frameworks will run it for me as I edit.
In a perfect scenario, all the code we work has programmatic tests. I can start them, and some should fail when I applied changes. If tests pass that may mean either test were incomplete or I made my change in a way or place that made no difference. Sometimes I'd have to verify the outcome empirically. Even then, though, I would add new tests before and after my change to see what was the status quo and to ensure one will accidentally break my code in the future.
Simply that. Software development often looks like a repetition of the process described above.
Do you agree with this approach? Does it work for you? How you approach the code, you don't know.
What I write here may sound bad for some people, even offend them. I understand and tolerate movement towards "body positivity". Anyhow, I also see the dark side of it. Body positivity often hides or even promotes a lifestyle that leads to disability and premature death. As a person who lost very early a parent to an unhealthy lifestyle, please allow me to oppose that movement. I respect it but consider wrong and harmful.… read more…
4 min min read - November 7, 2020
Martin has started primary school, so thoughts about education and the future began to gather in my head. Luckily instead of panicking and Googling, I've turned towards some literature. Thanks to a brilliant book by Steve Biddulph - Raising Boys in the 21st Century I realised that our progress so far is far better than we should expect. As for trilingual four-five year old, he picks up phonics and numbers pretty well, can use various devices, tell stories, learns to describe emotions, shows compassion, empathy and care. Despite still weak English, he manages to build strong relations with other children. He even can perform simple "programming" with Scratch and CodeSpark.… read more…
3 min min read - November 4, 2020