My post about Apple’s “SillyBalls” example program had a loose end. The mysterious phrase “Skippy Blair special concept” appears in the comments of SillyBalls.c, but what did it mean? So I was thrilled to receive an email last week from Jeremy Penner that explains everything! Jeremy did some amazing detective work to uncover the true identity of “Skippy Blair.” The email is so good that I’m posting it here in its entirety.| devnonsense.com
When you think of Apple, the company and its history, what images come to mind? Perhaps a black-and-white photograph of the two Steves with the Apple ][, the beige Macintosh of 1984, Jobs on stage unveiling the iPhone. Less remembered, but still part of that history, was a wacky example program that Apple released and maintained for over two decades. I’m referring, of course, to SillyBalls. In case you never had the pleasure of running this program, allow me to describe the experience.| devnonsense.com
sneakernet: /snee·ker·net/, n. Term used (generally with ironic intent) for transfer of electronic information by physically carrying tape, disks, or some other media from one machine to another. “Never underestimate the bandwidth of a station wagon filled with magtape, or a 747 filled with CD-ROMs.” Also called ‘Tennis-Net’, ‘Armpit-Net’, ‘Floppy-Net’ or ‘Shoenet’; in the 1990s, ‘Nike network’ after a well-known sneaker brand. – Eric S. Raymond 1 There was a brief...| devnonsense.com
TL;DR I ported GLFighters, a game written for Classic Mac OS in 2001, to WebAssembly! You can play it online at: devnonsense.com/GLFighters-SDL Table of contents Background Porting Strategy Linux Port Flipped textures Illegal instruction File loading Random SEGFAULT Sound sampling rate Z-Fighting Skybox seams Linux port working! WebAssembly Port Emscripten TGA files fail to load Page unresponsive Legacy OpenGL broken Slow motion Fixing texture loading Pink skybox textures Power-of-two texture...| devnonsense.com
Over the years, I’ve accumulated a few computer books, some of which sit on the top shelf of the bookcase behind my desk.| /dev/nonsense
Wifi router ban I currently live in student family housing at the University of California, Berkeley. Several years ago, Berkeley IT announced a new policy for wifi routers: Effective July 1, 2024, use of personal routers will no longer be permitted at UVA [student family housing], as is the case in all other campus housing. Residents who continue to use a personal router after this date may be notified to shut off the wireless broadcast or risk having the router blocked from usage on the cam...| devnonsense.com
Last week, I investigated an issue1 where iptables -L (the command| /dev/nonsense
This morning, I saw the sad news that Bram Moolenaar passed away yesterday. I never knew Bram personally, but I knew his work. Vim, the text editor he created and maintained, has been woven into the fabric of my life for nearly two decades.| /dev/nonsense
Why is the life of a mouse not absurd? The orbit of| /dev/nonsense
Sometimes at work I need to troubleshoot iptables rules in a Kubernetes cluster. The intuitive approach is to use kubectl debug to start a container, then run the iptables command.1 However, this fails with a confusing error:| /dev/nonsense
While working on aretext, I often need to lookup ASCII character codes. Unfortunately, the top search results for “ASCII codes” are absolutely filled with ads. This makes me sad for the state of the world.| /dev/nonsense
The music teacher drove from school to school, carrying a leather bag and smelling like cigarettes. We waited in the hallway until he arrived and unlocked the door to the music room. Then waited in line to tune our instruments at the piano, one by one.| /dev/nonsense
When I went to high school, things started disappearing.| /dev/nonsense
This morning, I joined the eCHO livestream to chat about a feature I worked on for the Cilium 1.12 release! Discussed delegated IPAM and my experience as a first-time contributor to the Cilium project.| /dev/nonsense
This is a story that begins with some code I wrote and ends with a rejection.| /dev/nonsense
It took nearly two years, but I finally built the homelab I always wanted.| /dev/nonsense
Starcraft was the first game I played online. My friend and I would dial each other over a 56K modem. I remember wondering why he kept ending his chat messages with “:” and “)”.| /dev/nonsense
On Sunday, I presented a lightning talk at the FOSDEM 2022 conference. Usually, FOSDEM takes place in Brussels, but recently it’s moved online. That was fortunate for me, because otherwise I probably would never have submitted a talk proposal!| /dev/nonsense
I tend to rewrite code. A lot. The terminal-based text editor I’ve been building, aretext, started as a Rust project, but after a month I rewrote it in Go. At one point, the editor embedded a Python REPL, which I later ripped out and replaced with a searchable menu. I completely rewrote the input interpreter, syntax highlighting parser, word movement calculations, and fuzzy find algorithm – multiple times!| /dev/nonsense
Over twenty years ago, I wrote my first networked program, a multiplayer card game. My original plan was to position two iMacs directly facing each other, six inches apart, and use the built-in infrared port to transmit data. Then my dad bought me an Ethernet cable – this proved a much better solution. For LAN networking, the program used the AppleTalk protocol, sending the entire game state (several KB!) between clients on every frame. Trying to connect to a friend’s computer through the...| /dev/nonsense
Update 2023-01-09: gospleunk has changed significantly since this post was written. It now uses the built-in Go parser and type-checker to implement “find definition,” “find-references,” and more! See the post implement “find definition” in 77 lines of go for more details.| /dev/nonsense
I created an account on GitHub in December of 2012, which is almost exactly nine years ago. The chart below shows the number of public contributions (mostly code changes) I made each year:| /dev/nonsense
After a long hiatus, I am rebooting this blog!| /dev/nonsense
For the past nine months, I have spent almost all of my free time working on a coding side project. This is surprisingly common behavior for software developers. Some of us spend the entire work week coding for a company, then choose to continue coding as a hobby in our mornings, evenings, and weekends. I plan my work around my two-and-a-half-year-old daughter’s sleep schedule.| /dev/nonsense
One weekend, my dad needed to learn CORBA for work. My mother drove the family to the Barnes & Noble on Stevens Creek Blvd. Three hours later, when we returned to pick him up, my dad had bought, and mostly read, Client/Server Programming with Java and CORBA. The cover showed two cartoon aliens drinking coffee at a diner.| /dev/nonsense
The original iMac came in only one flavor, but it still had a name: Bondi Blue. If you touched the CRT monitor, you could feel static electricity; a magnet would bend the colors. The mouse was round and had a single button.| /dev/nonsense
Tamagotchi was released in the US in 1997. It was a pink, egg-shaped device with a 32x16 pixel display and three buttons. The display showed a tiny digital pet. The buttons provided the pet with food, recreation, and medicine. If you neglected the pet for too long, it would get sick. This was designed to teach Japanese children responsibility. Everyone in my elementary school was desperate to own one.| /dev/nonsense
video game puzzle obsession| devnonsense.com
This is a follow-up to my previous post about some mysterious TCP connection timeouts in the UC Berkeley wired network. I received many thoughtful emails in response to that post, and there was an excellent discussion on Hacker News. I’m very grateful to everyone who spent time helping with my ridiculous home networking issues. Since then, I’ve learned some new information that (mostly) solves the mystery. In this post, I’ll first summarize the main theories people suggested, then tell ...| devnonsense.com
For over a year, I’ve been investigating a strange issue with the internet in my apartment. I’m posting the details here in case someone more knowledgeable than me can solve the mystery. I live in graduate student housing with internet provided by the university campus. Usually things work reasonably well, with one exception. On the wired network, I cannot connect to IP addresses used by Bunny CDN.1 Many websites use Bunny CDN to serve static assets.| devnonsense.com
My first real tech job was as a test engineer at edX. I was hired1 in 2013, a few months after Harvard and MIT invested $60 million in the company. This was at the height of excitement for massively open online courses (MOOCs). In June, Anant Agarwal, then president of edX, was interviewed on The Colbert Report, and the influx of traffic promptly took down edx.org. I think there were a handful of courses on the platform that first year, but it quickly grew to hundreds, then thousands.| devnonsense.com
This post explains how to install K3s on Fedora CoreOS. K3s is a lightweight Kubernetes distribution and Fedora CoreOS is an image-based Linux distribution for containerized workloads. With Fedora CoreOS, you get a bulletproof, minimal host system with atomic updates. Installing K3s allows you to deploy applications using standard Kubernetes tools like kubectl and helm. Honestly, why wouldn’t you use production-grade container orchestration to self-host an RSS reader or whatever?| devnonsense.com
After nearly three years of development, aretext has reached version 1.0! Aretext is a minimalist terminal-based text editor with vim-compatible key bindings. In this post, I’ll present the main changes since the last version, reflect on the journey from initial idea to 1.0, and discuss the future of the project. New syntax languages Syntax highlighting is now available for bash shell scripts and XML! These also work well for related languages like POSIX shell and HTML.| devnonsense.com
Most integrated development environments let you quickly jump from a symbol to its definition. In this post, we’ll implement a simple version of this feature in just 77 lines of Go code. Along the way, we’ll learn how to use the Go parser and type-checker included in the standard library. Let’s go! Where we’re going By the end of this post, we’ll have built a command-line tool that does this:| devnonsense.com
Ingemar Ragnemalm first released the Sprite Animation Toolkit (SAT) in 1992. “I have always liked to make computer games,” Ingemar wrote in the SAT manual. “It has been one of my hobbies since the late 70’s. When I started using Macs, of course I wanted to make some games for it too.” After writing many games, he had developed some shared code for sprite drawing and other utilities, so he released it as a library.| devnonsense.com
The 0.7 release of aretext is now available! Aretext is a minimalist, terminal-based text editor with vim-compatible key bindings. In this post, I’ll highlight some of the main changes and reflect on the direction of the project. Additional vim commands This release adds support for several vim commands: Search for word You can now use star (*) and pound (#) in normal mode to search forward/backward for the word under the cursor.| devnonsense.com
This post is an attempt to explain the incremental parsing algorithm aretext uses for syntax highlighting. Like the rest of aretext, parsers are implemented in Go for portability and performance. Most people do not consider Go a functional programming language; nonetheless, aretext’s parsers rely on functional programming patterns. In this post, we’ll see how to implement these patterns in pure Go to build parsers that are fast and expressive. Problem Syntax highlighting is a special case...| devnonsense.com
Version 0.6 of aretext has been released! Aretext is a minimalist, terminal-based text editor with vim-compatible key bindings. Here’s what’s new! Markdown syntax highlighting Aretext now supports syntax highlighting of markdown! It looks like this: The current implementation supports most of the CommonMark 0.30 spec, including: Headings Links Emphasis and strong emphasis (bold and italic) Bulleted and numbered lists Code blocks The new markdown parser has been validated against the Commo...| devnonsense.com
KubeCon this year featured a panel discussion of IPv6 adoption. One of the panelists mentioned in passing that many organizations are unprepared for the security implications IPv6. With IPv4, most addresses were hidden by NAT; with IPv6, addresses are publicly routable. Firewalls can block external traffic, but might not be configured correctly. So I did an experiment on my home network. Would enabling IPv6 expose my devices on the public internet?| devnonsense.com
A few weeks ago, I implemented syntax highlighting for markdown in aretext, the minimalist vim clone I’ve been building. Like most context-sensitive languages, markdown is difficult to parse. Although it handles only a subset of the CommonMark 0.30 spec,1 my implementation required 845 lines of Go code. Parsing is especially tricky because the code needs to handle any document a user might open. It can’t crash or enter an infinite loop.| devnonsense.com
Vim was my preferred text editor for nearly eighteen years, until I switched to aretext in 2021. I appreciated vim’s efficiency and ubiquity, the way I could rely on it regardless of what project I was working on or what machine I had ssh’d into. Like any software, however, vim reflects the time in which it was written. In many cases, vim optimizes for speed above all else, an approach that made sense given the limitations of late ’90s computers.| devnonsense.com
Today marks the fifth release of aretext, the minimalist text editor with vim-compatible key bindings! This post describes the highlights. (Wait, what’s that? You say you want to install it right now? Well, then just go straight to the installation docs!) Faster fuzzy menu search Aretext uses a trie-based fuzzy find algorithm for selecting files in a menu. This worked well for most projects… until I ran it after building Kubernetes.| devnonsense.com
This is the second post of a two-part series on Starcraft and late-90s networking. Part 1 describes Starcraft’s many connection options. Configuring Starcraft networking in 1998 was an adventure. There were four different connection options (plus AppleTalk on Macintosh computers), each of which required specific software and hardware to function. How did anyone figure this stuff out? It turns out that the Starcraft CD included detailed support documentation. Today, this provides a glimpse o...| devnonsense.com
Writing about multiplayer Starcraft reminded me how strange networking was in 1998. I remember connecting a computer to a modem, which was connected to a phone line (many homes had a second phone number specifically for this purpose). The modem would dial a number and “talk” to a modem on the other end.1 Networking two computers over a phone line seems bizarre to me now. You could connect without an IP address, packet switching, routers, network address translation, or firewalls – all t...| devnonsense.com
I wanted to run the original Starcraft, released in 1998, on my Linux desktop using QEMU. Thus began my six hour rediscovery of computing in the 90s, an era when installing working software required wizardry, persistence, and luck. Windows 98 First, I installed Windows 98 in QEMU using an ISO that I found online. Pentium 2 processor, 128 MiB of RAM, and 1GiB disk should be more than enough to handle Windows 98!| devnonsense.com
No one types perfectly. To compensate, many programs use “fuzzy find” algorithms to retrieve records close to what a user typed. Accidentally typed “quck” or “quack” when you meant “quick”? No worries! Fuzzy find will retrieve what you meant anyway. This post explains the fuzzy find algorithm used in aretext, the terminal-based text editor I’ve been working on. Design Goals In a typical editing session, the user will search for commands to execute or files to open.| devnonsense.com
Starting a two week vacation today, so I’ve planned a small project: a Go-specific version of ctags. I’ve used ctags in the past to navigate a medium-sized Go monorepo, but there were some pain points. Re-indexing usually took about a minute, and, at least by default, ctags doesn’t search the standard library or Go module dependencies. I’m imagining a tool that’s easy to use from the CLI as well as from within an editor like vim or aretext.| devnonsense.com
mac game development in the early 2000s was quirky and awesome| devnonsense.com
failing to write novels and video games| devnonsense.com
meeting a wizard| devnonsense.com
A few months ago, I found myself wondering how a command like ping 1.1.1.1 works from within a private network. In most private networks, multiple hosts connect to the Internet through a router. For IPv4, the router performs network address translation (NAT) by rewriting the original host’s source address to the router’s public IP address. The router can lookup the correct host for a reply packet based on the packet’s port field, at least for protocols like TCP and UDP.| devnonsense.com