Pinned ·

Rust: Render `serde` Errors For Humans Using `format_serde_error`

Foreword The serde crate is certainly one of the finest tools in the box. I rarely work on a project that does not make use of it; most of the time it is a user-facing usage - prominently: configuration files. Now, humans make mistakes, and I think software should be blameless an…

Pinned ·

Rust: How to Unwrap Multiple Required Options

Let's say we have a function that returns an Option. fn get_option() -> Option<bool> { Some(true) } We call it in main for this example and print the value using the dbg! macro: fn main() { let b = get_option(); dbg!(b); } This will yield: [src/main.rs:7…

Pinned ·

How to Update NixOS

I recently wrote a post called How to Setup NixOS on a Raspberry Pi and haven't touched the system I setup there in a little while. Now I booted it back up and found that there has been a new release of NixOS in the meantime. So here is a quick how-to on updating NixOS: Login a…

Pinned ·

How to Use Your Android Device as Webcam on Linux

I love to work from home. And I like my workspace to be ergonomic as well. Ergonomics at the workplace is usually something you do for yourself, however recently I did some improvements for everybody who interacts with me in order to improve their experience as much as I can from…

Pinned ·

How to Setup NixOS on a Raspberry Pi

This article will walk through the steps of installing NixOS 20.09 on a Raspberry Pi Model 3 B+. At the time of this writing (May 2021) NixOS officially supports running on said board using the aarch64-linux build. Many more boards are provided with community support though. What…