Below you will find pages that utilize the taxonomy term “Rust”
2024 Programming EOY
This year was a bit light on programming. I was focused a lot on gaming, cooking, and Tabletop Gaming. (No surprise if you’ve been reading my December blog posts) I constantly found myself desiring to code and I definitely had a few ideas - like a utility to extract EXIF data out of my images for use in Hugo. But when I would sit down at my computer I often found myself preferring to play Cities: Skylines II or Against the Storm. (More on that when I post my EOY video game post) As per usual, let’s go month-by-month (after the first quarter that is)
Advent 2024 Day 02
Time once again to review my Advent of Code solutions! Also the latest die or dice from the Dice Envy Advent Calendar; scroll below the AoC code to see today’s die.
Programming Jan-April 2024
This year started off pretty light when it came to programming because I’ve been addicted to the video game Against the Storm since last winter. But I eventually started working again on various projects - some old and some new. I didn’t do any programming in January, so we’ll start in February.
February and March
Over these two months I worked on my replacement for web access to my Taskwarrior TODO list because Inthe.am had shut down. In February I got the podman containers set up - one to run the taskd server and one to run the website I’d coded up in Flask. In March I had to write some rudimentary Javascript to get the website to highlight the selected tab (Overdue, Today, This Month, etc). The rest of the interactivity on the site works using HTMX, letting me focus on Python instead of Javascript, but I just wasn’t able to get that part of the site to work without a tiny bit of Javascript. I also added some fixes because the date/time widget assumes UTC. Of course, now that I have it all working correctly and get lots of use for it (especially when I’m at work and I want to quickly get something out of my brain’s short-term buffer), Taskwarrior went to 3.0 which completely changes the way the program works, the API, and the way syncing works. I think in the end it’ll be for the best, but it’s annoying that I need to figure this out. That may involve finally learning how to use PyO3 to interact with Rust or re-writing part of my backend in Rust. We’ll have to see where that goes.
A few thoughts on Programming languages
Just a few thoughts on programming languages that have been rattling around in my head this week, but which don’t each merit a full blog post. The main theme is that the culture behind each programming language leads to some interesting choices, as is the case with spoken languages.
This week I started learning how to program in Rust. Even though I’m using the project-based Command-Line Rust to learn, the author still went with the traditional “Hello, world!” project for the first intro to the language. I was also working on a Go project last week and so it immediately stood out to me that (at least as taught by this author) Rust has the print! macro that allows you to succinctly print to the command line. By contrast, Go requires importing fmt before you can print. This was the first topic that was swirling around in my head this week. What makes language designers choose whether printing output (one of the most basic things a program can do) is built-in or requires an import. I even remember back when I was learning Java in undergrad (I think it was Java 1.8, but I don’t remember) we had to use the savitch library just to get program input (another very basic computer program concept). As I thought about it, I wondered if it has to do with thoughts around compilation and whether the language designers think you’re mostly making user-interactive programs or libraries? It makes sense to me that scripting languages like Python, Ruby, and Perl would have print built-in since you always have to have the interpreter along with you, so all the basics should be there. (The original Batteries Included Python promise, for example) But perhaps the Go developers thought you wouldn’t always be printing to the command line so a more efficient binary could be compiled by forcing you to import the functionality? I’m not entirely sure.
Mozilla's Legacy
A few days ago I read this article over at Tech Republic about how, Mozilla’s greatest achievement is not Firefox, but the Rust programming language. They point to Firefox’s declining numbers in the face of Chrome and Chromium-based browsers and I’m inclined to agree with the author. There is, of course, a kind of poetry to this. Although Netscape was one of the first dot-com companies and beat Microsoft to the punch at creating the first mainstream web browser, it’s not Netscape Navigator which is its greatest legacy. Instead it’s spinning off into Mozilla and, the most poetic part, the creation of the Javascript programming language. (Javascript was written in just a week and a half and this episode of Red Hat’s Commandline Heroes podcast does an excellent job documenting it)
A Daily Photo: Rusy Truck
What is it that intrigues us about rusty cars? On flickr there are hundreds, if not thousands, of such photos. I also see them in books. I think it’s partly because of the colours, partly because it reminds us of our own mortality, and perhaps partly leftover cultural hatred of machines.