The long way through Software Craftsmanship

Building private tools in the open

Aug 31, 2024 - 5 minute read - Comments - toolprivate-toolseparationversionrebaserepository-patternrewrite-history

Introduction It is very common to develop private tools in private: private git repositories, private servers, private data, private everything. But what if you want to obtain the benefits of developing in the open while keeping your privacy? Context and Applicability We have been developing tools like this. It works well, you just have to be careful on what gets committed where. Alternatives: Keep all development hidden (e.g., private repositories, private cloud) Hide the data using git-crypt in the public version Merge the public and private versions into one using submodules How to Split the tool in two parts: the public part and the private part.

The Threading Macro (clojure) equivalent in Python

Jul 22, 2023 - 2 minute read - Comments - equivalencethreading-macroclojurelispmacropythonlanguagelanguage-equivalence

Introduction In any programming language, it is common to compose functions by pipelining functions: h = g ∘ f such that h(x) = g(f(x)). The function f is applied first, then g, then the following. 1 For me, it would be more comfortable and easy to understand to write it f COMPOSE_THEN g, indicating that this function composition is not the usual, but a different operation. Introduction in Clojure This function composition can be written in Clojure by pipelining or chaining functions:

The value of worthless projects

Sep 11, 2021 - 3 minute read - Comments - pet-projectprojectpersonal-projectworthless-projectdeliberate-practicebusinessidearayw

Many people suggest pursuing personal projects in their free time 1. Some of these projects can be turned into businesses (but then you need to work on other parts, not only developing the project). Among these projects, you can also find worthless (in the economic term) ones. These are useful, among other reasons, 1) for having fun 2) for getting away from a work-related mindset 3) for deliberate practice. Practicing with these projects gives you the opportunity:

Using a Native C Library in Android

May 2, 2021 - 5 minute read - Comments - androidnative-libraryandroid.mkkotlingradleccppabijni

For a client, we needed to integrate a pure C library into an android application. The library is written in C (not C++), the application in Kotlin. Context We have created an Android application, that is using a native C library. This library provides an upgrade in performance over using a JVM library. For this particular example, we’re showcasing how to integrate libsodium, but this can be expanded to any other library.

On private but leaked information in a SaaS

Nov 4, 2019 - 3 minute read - Comments - gitexamplesensitive-informationcodenameuuidtoolboxtoolstealth-modenon-disclosure-agreementsecurity-clearance

This is another tool for your toolbox: how to uncorrelate public and private information. Context Context: there are clients who have sensitive information. Some is just ‘companies being stealth’ (e.g., don’t want to make public until launching), some is just protected by a Non-Disclosure Agreement (NDA), some are protected by security clearance. The more sensitive, the greater protection needed. This tool applies to all sensitive information, regardless of where it’s stored or how it is used.

Automatically keeping the intermediate history of your work using git

May 29, 2019 - 2 minute read - Comments - tooltoolboxgitdocumentationspikeautomationmarkermarker-interfaceflowproblemsolution

This is another tool for your toolbox: using git to automatically document your development process (special cases only.) Context When I’m spiking a feature, I usually get in the zone (e.g., Csikszentmihalyi’s Flow), and I can forget my good engineering practices, searching for that desired answer. After a few of those bouts of coding, you realize you’re wandering. You circle around, get lost, get back on track, then get lost again.