a tumblelog
Sat 17 Oct 2020

Coding Tip: Try to Code Without If-statements

When I teach beginners to program and present them with code challenges, one of my favorite follow-up challenges is: Now solve the same problem without using if-statements (or ternary operators, or switch statements).

Source: Coding Tip: Try to Code Without If-statements, an article by Samer Buna.

No, The iPad Pro is not a development machine

iPads, which is to say any iPad made in the last three years (yes, even the base models) has more than enough power to run development tools and compile most codebases you would care to. The more recent iPad Pro models even give modern Core i9 laptops a run for their money in some metrics.

Why then do we not see development tools on the iPad? Or at least, why do we not see more of the development tools we’re used to seeing on the platform. The reason, unfortunately, is iPadOS.

Source: No, The iPad Pro is not a development machine. But it so easily could be, an article by Jay Rodgers.

Self-hosting Git

cgit is very bare bones. It is cgi web interface interface to git, and nothing more. You may browse repositories, view diffs, commit logs and even clone via http. If you are looking to replace Github with cgit, keep in mind that cgit does not handle issues or pull/merge requests. If people wish to contribute to your work, they would have to send you a patch via email.

Source: Self-hosting Git, an article by Akshay Oppiliappan.

Tumblelog 4.1.0

In the evening I finally released an updated version of tumblelog; a static blog generator that comes in two versions: a version written in Perl and a version written in Python. I use mostly the Perl version to generate Plurrrr but now and then run the Python version to verify it generates the same output given the same input.

This version fixes a bug I found using Ahrefs Webmaster Tools. I also used pylint version 2.6.1-dev1 to improve the Python code. The score went from 8.57 to 8.85. Some of the issues found where also in the Perl code, so I corrected the Perl version as well.

Next I used perlcritic version 1.138 to critique the Perl version of tumblelog. Several of the issues found were fixed.

Last, but not least, I factored out the font stacks of all styles into a separate _fonts.scss file and used stylelint version 13.7.2 with a custom .stylelintrc.json to clean up the styles for tumblelog.

Version 4.1.0 of tumblelog is available on GitHub. As always feedback is very welcome.