Brain Dump

Recent content on Brain Dump
https://geoff.tuxpup.com/ (RSS)
visit blog
Fischer, Part 4: Configuring Django Authentication
8 Oct 2024 | original ↗

Today I'd like to experiment with some nice interfaces for tagging and showing tagged bookmarks. But it feels too clunky to log into the django admin then navigate back, so first I want to get Django authentication set up. I suspect that if this turns into something I want to share with others, I'll eventually wind up with allauth, but that feels...

Fischer, Part 3: Importing and Exporting Bookmarks
6 Oct 2024 | original ↗

In order to further iterate on Fischer, I'm going to need to be able to test with a reasonably large pile of bookmarks. That's going to get tedious quickly if I can't import and export them as I experiment. In the past, the shortest path to doing this has been using django-import-export and either a script or django admin integration. I'd prefer...

Fischer, Part 2: Tagging
5 Oct 2024 | original ↗

In Part 1, I learned how to do views and routes in nanodjango, got some basic templates set up, and vendored Pico CSS to make those pages look a little nicer. Tagging is going to be an important part of making this all work the way I want, and the easiest way to solve that is with django-taggit. I'm tackling this next so I can learn whether...

Fischer, Part 1: Getting Started
4 Oct 2024 | original ↗

I know there are a few new practices that I should adopt as I start new projects, but part of the purpose of this one is trying out nanodjango. So I’m keeping my other stuff the same, including pyenv, black, and poetry usage, for now in order to save my “innovation tokens.” Some Quick Ceremony to Make a Comfortable Environment cd fischer git init...

'90s-style Start Page for my Browsers
3 Oct 2024 | original ↗

Lately, I find myself missing the dynamic start pages we used to set for our browsers in the late 1990s. The ones I liked eventually turned into search engines, got crapped up by ads, or just plain went away. All of the above, in many cases. For a while, I didn’t miss them, because feed readers and synchronized bookmarks kind of took their place,...

xlsx-dict-reader 0.2.0, or, publishing to pypi in 2024
25 Mar 2024 | original ↗

For the first time in quite a while, I caught the urge to publish a package to pypi today. The happy path for publishing a pure python package felt less obvious than I think it should’ve. Here’s what I did. The package in question is published here, and the source code is available on sr.ht. It’s the beginning of a youth baseball season. One of...

Fantasy Baseball 2024
19 Feb 2024 | original ↗

After a few years' layoff, I’m playing fantasy baseball again in 2024. Not only is this league quite a bit different from the one I used to play, the online resources for player research have changed over the past few years. This post collects some things that seem useful to me. Fangraphs has grown and changed quite a bit. Baseball Prospectus...

Upgrading an Alpine Linux Installation After Waiting Way Too Long
15 Jan 2024 | original ↗

I’m blogging today’s yak shaving exercise because I found web searches challenging for some of this. And hopefully writing them down here will both help improve those searches and help me remember. Also, I am determined to blog more in 2024. This post really is mostly about snags in my Alpine Linux upgrade adventure, but I’d like to share some...

dj-notebook: the REPL I've Always Wanted for Django
22 Oct 2023 | original ↗

This year, I’ve really started to like jupyter notebooks. I first tried them out several years ago, but they’ve only just started to click for me. They haven’t changed; the difference is how I think about them. When I initially tried them, they felt like writing untestable code in a browser, where you could get yourself into an unknowable state...

Hypermedia Systems - Using Django - More htmx patterns
14 Oct 2023 | original ↗

I’m working through Hypermedia Sytstems using django and htmx in public. This post starts applying the patterns from Chapter 6: More Htmx Patterns. In the last post, I finished working through Chapter 5. If you haven’t read the prior posts, they’re linked from the introductory one. The code can be found on sr.ht. To pick up where this post does,...

Hypermedia Systems - Using Django - Adding htmx (pt 2)
13 Oct 2023 | original ↗

I’m working through Hypermedia Sytstems using django and htmx in public. This post continues to work through Chapter 5: HTMX Patterns. In the last post I finished the data validation parts of the chapter. If you haven’t read the prior posts, they’re linked from the introductory one. The code can be found on sr.ht. To pick up where this post...

Hypermedia Systems - Using Django - Adding htmx (pt 1)
12 Oct 2023 | original ↗

I’m working through Hypermedia Sytstems using django and htmx in public. This post picks up with Chapter 5: HTMX Patterns. If you haven’t read the prior posts, they’re linked from the introductory one. The code can be found on sr.ht. To pick up where this post does, start from the tag contacts-app-web1.0. Even though it’s possible (and...

Hypermedia Systems - Using Django - Contacts.app Web 1.0 edition
11 Oct 2023 | original ↗

I’m working through Hypermedia Sytstems using django and htmx in public. This post covers building out the Web 1.0 edition of the book’s contacts app. For background on this series of posts, see the introduction. To follow along with the code, you can access the repository at sr.ht. If you’d like to follow along starting here, check out the...

Hypermedia Systems - Using Django (introduction)
11 Oct 2023 | original ↗

Carson Gross, Adam Stepinski and Deniz Akşimşek have recently published their work, Hypermedia Systems and have generously made its entire content available online without any fee. Over the past two years or so, I’ve found myself reaching for HTMX more often when I build sites. It’s been a really nice way to work, but I’ve definitely learned it...

Flipper Zero Notes
2 Oct 2023 | original ↗

A friend recently very generously gifted me a flipper zero, and it’s been a lot of fun to kick the tires. After exploring the stock firmware for a while, I wanted to customize it more than was possible with stock firmware, play with some apps people have built, and try my hand at running my own code on there. Initial Setup First, I grabbed a...

PSA: Docker Will Edit Host-Based Firewall Rules For You
19 Feb 2023 | original ↗

Over the past week or so, I’ve been trying out using Docker to deploy a Django site on a VPS. My preferred setup for that is to have Caddy running on the host, not in any container, as a reverse proxy. (It’s a single, static binary; I don’t see any joy in wrapping that in a container.) In the past when I’ve hosted similar things, I just ran...

Working on a Dependency Locally
22 Sept 2022 | original ↗

Aside: I let my need to stop the reading journal project for a while make me pause my blog posting as well. That was unintentional. I still plan to post 100 posts this year even if that series needs to wait. My first open source contributions are old enough to have a beer in the US by now, as is my first python code. But I’ve always found it...

Django, HTMX, and front-end scripting
14 Jul 2022 | original ↗

As I’ve mentioned a few times, HTMX is really growing on me for building web things lately. When stacked on top of Django, it lets me mostly write server side code, which is my comfort zone, but get pages that load and behave the way people expect them to in 2022. It doesn’t free me from all need to write stuff that runs in the browser, though....

How I Start: Django, Tailwind, HTMX (part 5)
10 Jul 2022 | original ↗

In part 4 of this series, we got forms in place to add and edit books in the library, then made them look better using django-crispy-forms. The many-to-many relationship between books and authors brought some weaknesses of the Crispy Tailwind theme to light, and it took a bit of effort to address that. Now it’s time to get deletion working...

How I Start: Django, Tailwind, HTMX (part 4)
8 Jul 2022 | original ↗

In part 1 and part 2, we got the basic project workflow set up. Part 3 saw some initial models and views that were tested using the Django admin UI. Now it’s time to add library CRUD to the reading_log application itself. Where code is discussed below, I try to copy everything that’s relevant inline. I’m sure I missed a few things. The entire...

Adding `shell_plus` for Django to PyCharm's Python Console
27 Jun 2022 | original ↗

I’m blogging this because I find myself looking it up repeatedly. Every time I start a project, I eventually hit a point where I use the REPL quite a bit. Usually I want to use it from PyCharm’s python console. And I usually find myself manually typing 5 or 6 commands at the start of each session that shell_plus from django-extensions would give...

How I Start: Django, Tailwind, HTMX (part 3)
25 Jun 2022 | original ↗

In part 1 and part 2, we got the basic project workflow set up. Now it’s time to add some basic models and views. Tweak tailwind.config.js Before we get into the meat of this, it’s necessary to alter the tailwind configuration so that the tailwind CLI will look for templates in subdirectories. This is only necessary because of how I choose to...

How I Start: Django, Tailwind, HTMX (part 2)
24 Jun 2022 | original ↗

How I Start: Django, Tailwind, HTMX (part 2) In part 1, I set up the project, a sensible .gitignore, tailwind, and live reloading along with some run targets for PyCharm. Now it’s time to finish up the housekeeping. Housekeeping: Move Configuration into the Environment This doesn’t strictly need to be done at this early stage, but I find that...

How I Start: Django, Tailwind, HTMX (part 1)
23 Jun 2022 | original ↗

How I Start: Django, Tailwind, HTMX (part 1) I wanted to try out some "modern" front-end development for a while, and I did. FastAPI is great. So is Svelte. But even though I found creating APIs that way to be a breeze, building a whole site that way felt much slower and heavier than using traditional server rendering. So I decided to give...

Is This Thing On?
22 Jun 2022 | original ↗

I feel like restarting the blog. Let’s see how long it sticks this time. My goal is at least 100 posts in the next 12 months. I have, on multiple occasions, harbored ambitions of making this blog a daily thing. Clearly, I’m not built for that. But after not posting for a while, I feel like it’s worth trying things out again, with another run at...

A Nice Regex Tester I Keep Needing To Search For
19 Oct 2020 | original ↗

About every two or three months I need to write a regular expression that’s complex enough I don’t get it correct on my first try. Then I search for this site, and wish I’d just started writing my expression there. I hope that writing it down and posting it here will help me remember that next time.

Hosting Side Projects in my Basement
18 Oct 2020 | original ↗

For trying out new things, sometimes I want to make them accessible from the internet. I’ve got a small reverse proxy VPS on one of the cloud hosts. This is how I currently set them up on a VM in my basement and expose them via that proxy. Writing out all the steps from install to accessibility makes this seem like a lot of work, but it isn’t...

Stock Toolkit: Conclusion
15 Oct 2020 | original ↗

My toy stock toolkit application is “feature complete” for now. I’m very happy with both the quality of the tooling and the ease of using it. Svelte combines well with Tailwind and lets me get things done on the front end more easily than I imagined. This post summarizes what I made along with what I’ve learned. My code is available in this...

Tailwind CSS and Svelte
8 Oct 2020 | original ↗

Part of the appeal of Smelte was Tailwind CSS integration. After going back and trying Smelte some more, I concluded that it’d be easier to use Tailwind directly, at the cost of giving up some very convenient widtgetry. The Smelte widgets aren’t comprehensive enough to use them all alone, and their customization of Tailwind makes it too hard to...

A Detour into Smelte
7 Oct 2020 | original ↗

I took a detour to try out the Smelte/Tailwind CSS UI gadgetry. I found lots to like about it, but it’s not the right thing for me right now. Read on if you’re interested in the detour. If you’re trying to follow how I got to my end state, go here instead to see how I set things up for vanilla Tailwind. Adding Smelte and Tailwind CSS I’m not a...

Learning FastAPI (3): "Stock Toolkit"
7 Oct 2020 | original ↗

Front-end development is the area where I feel most out-of-date today. While none of the technologies at play are exactly alien to me, I usually don’t do anything more elaborate than some templated HTML mixed with vanilla javascript plus jquery and bootstrap CSS. But while those sites are functional and even look OK sometimes, they often lack...

Learning FastAPI (2): "Stock Toolkit"
6 Oct 2020 | original ↗

As I’ve been trying to update the tools I lean on for quick web things, I am really enjoying using FastAPI with Svelte. These are notes about the development setup that I currently like. Fair warning: this is not battle hardened yet. I’ve used it to make a couple of toys and like how it’s shaping up, though. I give an overview of the stack here....

FastAPI + Svelte
5 Oct 2020 | original ↗

As I’ve been trying to update the tools I lean on for quick web things, I am really enjoying using FastAPI with Svelte. These are notes about the development setup that I currently like. Fair warning: this is not battle hardened yet. I’ve used it to make a couple of toys and like how it’s shaping up, though. I’m mostly trying to capture the...

Excalidraw
3 Oct 2020 | original ↗

Since I need to prototype a few web tools in the near future, I’ve been casting around to update the stack I use for that. The last time I consciously did that was several years ago, so I’ve had a lot to experiment with in order to catch up and land on some new practices that will help me quickly try out ideas in a way that will be appealing to...

Baseball App Wishlist
30 Sept 2020 | original ↗

Now that I’ve coached my kids and their friends for a few seasons, I have a fairly well-developed routine for getting ready for practices and games. Every time I do it, I’d like an app to help me with the following: Take scratches from the online RSVPs Randomize my batting order For teeball/rookies, make sure I’m spreading the fun of batting...

TRIM - Fedora 32 edition
29 Sept 2020 | original ↗

This week, I needed to declare the KDE experiment a failure. While there are many ways in which I prefer it to GNOME, there are just as many annoying quirks that I did not manage to tame or get used to. Since Fedora 33 is about to ship, Fedora 31 is about to become unsupported anyway, so it seemed like a good time to upgrade. Out of laziness, I...

Hacking a Cheap IP Camera
29 Sept 2020 | original ↗

I’ve been a little choosy about what’s allowed on my network for quite some time. Back when we were trying to adopt Ace the hound, I picked up a camera from Micro Center called the “Yi 1080p Home Camera”. It cost around $20 at the time, and claimed some great features. I did not expect that I was going to be happy with its activity on my...

Fun with Nginx as an API cache
25 Sept 2020 | original ↗

Over the past couple of years, I’ve felt like what is currently called “front-end” web development is a tremendous blind spot for me. It just so happens that current world events leave me curious about some data that is widely available via public APIs. My personal desire to understand some of the information about the world that those APIs...

Making VMWare Workstation launch on Linux 5.8
25 Sept 2020 | original ↗

I’ve needed to write something similar to this down before. Since I got used to that dance, it hasn’t been much hassle to keep VMWare humming away on my Fedora laptop. Maybe that’s because I don’t use it as heavily as I used to. Today I wanted to use the Workstation client to control my ESXi server. And it wouldn’t launch at all. Not only that,...

Source Debugging for LÖVE2D
11 May 2020 | original ↗

As good as existing editing tooling for LÖVE2D, sometimes source debugging is hard to beat. I don’t feel the strong need for an IDE; the tooling available for vim and VSCode is excellent for editing, reading and running these games. But especially without a compiler, it can be really helpful to be able to set breakpoints and inspect values at...

Distributing LÖVE games on Windows
8 May 2020 | original ↗

Not surprisingly, the kids are interested in the game projects I’m building for class. But they want to play on the TV. We have a little Windows PC hooked up there that’s already used for games and such. Fortunately, it’s not hard to package up the games. The wiki describes it reasonably well. Once again, being camped on 10.2 makes it a little...

I Will Miss Keybase
7 May 2020 | original ↗

Zoom has acquired Keybase. It’s hard to imagine that it will continue in anything much like its current iteration. I will miss it. (Except for the weird cryptocurrency thing they were pushing for a few months.) I haven’t found anything I like nearly as well for end-to-end encrypted chat. And their filesystem/git features were a great way to...

A REPL for LÖVE 2D 10.2
6 May 2020 | original ↗

Debugging in Lua has been a strange experience for me. The debugging tools are not as rich as the Python or C++ tooling I’m accustomed to. Two useful items are LOVEDEBUG, developed by several members of the community and DataDumper from the lua users wiki. Since we’ve camped on version 10.2, the current versions floating around won’t work for...

Sound Levels on Kdenlive
5 May 2020 | original ↗

Kdenlive is a powerful video editor that I find hard to discover features in. I’ve settled into a workflow where I record everything but the game play, then record the game play demo, then record a voiceover. Usually it just gets the sound levels right, but sometimes they’re out of balance. To change them, right-click on an audio track, choose...

Pushing to a Non-default Remote Branch
4 May 2020 | original ↗

Turning in assignments for Games 50 requires that each project be pushed to a separate branch on a github-hosted repository. I prefer to work in separate repositories, and host them on sr.ht. Git makes it fairly easy to work this way, but the syntax is a bit arcane and I never get it correct right away. Especially if I need to update the turned...

Thinkpad T480 Firmware Updates on Fedora KDE
3 May 2020 | original ↗

One of the great improvements that landed around Fedora 29 or so was the Linux Vendor Firmware Service. Because both Lenovo and Logitech are participating, that makes using Linux for my daily desktop environment on the Thinkpad T480 much better. Unfortunately, since I switched to Plasma instead of GNOME, the automatic prompts for firmware...

Trying out Aseprite on Fedora 31
2 May 2020 | original ↗

Installing Aseprite on Fedora 31 Since I’m trying my hand at some game projects, I need to edit sprites. People say nice things about several pixel-oriented paint programs. Probably the two that get the most nice mentions are Piksel and Aseprite. Piksel looks nice and is free, but it seems intended to be run in the browser with some online...

Supporting Gamepads in my LÖVE projects
1 May 2020 | original ↗

Working through a class at the same time as I have my kids doing schoolwork at home has its benefits. A big one is that they see me listening to a teacher, doing online exercises, reading, completing assignments, etc. It also nets me a couple of eager play testers for the projects. I have been surprised to see that needing to play on a laptop...

GNU poke binary data editor
30 Apr 2020 | original ↗

While catching up on the news after wrapping up my “flappy bird” clone project (more on that tomorrow, maybe) I ran across a tool I’d not heard of before. GNU poke is a new GNU tool intended to manipulate structured binary data. I think it’d be really useful for dealing with ASN.1. It is worth watching the author’s talk. His stunt editing is...

On Screencasting
29 Apr 2020 | original ↗

Because of the class I signed up for, I find myself needing to record and upload screencasts in order to turn in assignments. This caught me by surprise a little bit. I’ve never configured my system to do good ones, and didn’t really know where to begin on a Linux machine. My workstation is KDE Plasma 5 on Fedora Workstation 31. Here’s my setup...

Getting LÖVE 2D 10.2 running on Fedora 31
28 Apr 2020 | original ↗

Harvard has made several online courses available free of charge, for the time being. Looking at their offerings, CS50’s Introduction to Game Development caught my eye. I haven’t written a game in on the order of 25 years, and my son is starting to get interested, so it seemed like a fun thing to do. It is really amazing to see how some current...

Neat feature on Source Hut
27 Apr 2020 | original ↗

I’ve been doing a couple of online classes recently, and it’s nice to be able to stash things remotely for a variety of reasons. I’ve been using and liking the service at sr.ht lately for hosting my personal stuff. The interface there suits my taste more than either GitHub or GitLab does, and I really admire the way they are building their...

Reverse-Proxying HTTPS Traffic to a Server in my Basement Using Caddy and Wireguard
29 Mar 2020 | original ↗

Reverse-Proxying HTTPS Traffic to a Server in my Basement Using Caddy and Wireguard I’ve been experimenting with new web services lately, some of which I’d like to open up to my mobile devices. Punching a hole through my home network firewall is unappealing, though, as is standing up a new VPS for each one I’d like to kick around. I already feel...

Unknown
22 Mar 2020 | original ↗

Unknown (I don’t do politics. This will be an atypical post, and if you’re one of the tens of people who come here for the usual tech stuff, you’ll miss nothing by ignoring this post.) I filled out a census form today, for the third time in my memory. I don’t think they’ve changed a great deal since I started. But this time, for some reason, it...

Python and Google Sheets
29 Feb 2020 | original ↗

Using Google Sheets from Python The API for Google’s spreadsheets has seen a few revisions now, so there’s a ton of stale information floating around. This post is not a step-by-step tutorial, but it is meant to point to what’s working well for me right now, in Feb 2020. Libraries Three libraries are bearing most of the load for me: gspread -...

Anbox on Fedora 31
1 Feb 2020 | original ↗

Anbox is a containerized environment for Linux desktops that can run Android applications as if they were native. Overview Use DKMS to install kernel modules Use snap to install anbox Change the container api version Fix SELinux Install google apps and ARM binary support Install Kernel Modules Anbox requires two kernel modules that are not...

Pinebook Pro - First Impressions
25 Jan 2020 | original ↗

Earlier in the week a Pinebook pro found its way to my doorstep. I pre-ordered it in mid-December, when they announced a version with the ANSI keyboard layout. I picked it up for several reasons. First, I like what they’re doing to produce affordable, hackable hardware and want to vote with my dollars for that when I get a chance. And since I...

Making VMWare Workstation Work with New Host Kernels (on Fedora)
9 Jan 2020 | original ↗

I’ve been tempted on several occasions to convert my VM zoo from VMWare over to KVM. But up to this point, it doesn’t feel quite justified, so I keep on buying VMWare upgrades and using them on Fedora even though they do a bad job keeping their host modules up to date with the kernels Fedora uses. This problem gets more notable the farther you...

A Comfortable Arduino Development Environment
8 Jan 2020 | original ↗

I’m not really a hardware person. I can muddle my way through some basics, but it’s not my strong suit. I’m comfortable writing software, but sometimes you just want it to interface with physical objects. I find Arduino boards (and their clones) to be nice for that, mostly because of the variety of shields and sensors that can be had easily and...

Kitty and CoreOS
30 Nov 2019 | original ↗

kitty is my current favorite terminal emulator for desktop Linux. The one thing I dislike about it is that it is its own new terminal type, xterm-kitty and most remote hosts don’t detect it appropriately. So escape sequences and the like are a mess, and ncurses (and similar) apps get really angry. This is fairly easy to fix on most systems....

TRIM on a cheap NVMe SSD
5 Nov 2019 | original ↗

I used to be a die-hard, very happy Mac user. I’ve been using Mac OS in one form or another continuously since the late ’80s. And ever since the early 2000s, my favorite laptop hardware has been Apple’s. Coupled with a decent UNIX environment and the ability to develop for iOS devices, I was pretty attached. Unfortunately, I do enough work in...

Transmission Plugin on FreeNAS 11.2
1 Nov 2019 | original ↗

This is probably all obvious to any “real” FreeBSD people. And possibly to anyone who’s using a FreeNAS installation that hasn’t been slowly upgraded since 2013. But for better or for worse, I’m used to Linux these days and all of my habits around FreeNAS were cemented shortly after I installed my first one in 2013. So there were a few bumps...

↑ these items are from RSS. Visit the blog itself at https://geoff.tuxpup.com/ to find other articles and to appreciate the author's digital home.