Thursday, March 14, 2019

Every time I declare tab bankruptcy and close the 15 to 25 things I have open in a web browser, I suspect I’m losing state I will later regret being unable to retrieve.

That generalizes, I suppose. I have this sense that a lot of what we do in software is something like writing code before the use of version control systems became a norm.

All kinds of relationships and structures remain implicit, undescribed, and impossible to model because they live purely in ephemeral application state. The best we have in a lot of cases is fragile browser history, notification backlogs in e-mail, or logs accumulated on other people’s computers for purposes directly hostile to our interests.

Sunday, March 3, 2019

notes on notes

First of all, I wrote up some notes on my current note-taking process.

I started to do this the other day as a regular, dated p1k3 entry, but it got sort of long and I found myself wanting to do it as a standalone document that I could update over time. It seemed like a table of contents would be nice, but that’s not something that wrt supports, so I decided to see how hard it would be to add based on the hacky rendering script I wrote for userland.

That turned out to be a hassle to do well for various reasons, so I turned to Pandoc, which supports generating a table of contents out of the box.

There’s a Perl wrapper for the pandoc binary, so I first tried using that to add a simple <pandoc>…</pandoc> pseudo-tag to wrt’s markup processing the way I’ve done for Textile, Markdown, and other things in the past. It turns out that in order to get a table of contents out of Pandoc while still generating an HTML fragment (rather than a complete document), you have to write a custom template file. It also turns out that if you want to automatically put self-links next to headers, you need to write a custom filter to transform Pandoc’s abstract syntax tree.

I gave up on modifying wrt to handle this and switched to writing a small Makefile, a, and a template to generate HTML for inclusion by wrt. You can see the results here or on my gitea instance. I kind of hate the outcome and I’m not sure I’ll do anything this way again, but I definitely learned some stuff about Pandoc. I suppose this might be a useful example for someone.

Saturday, February 16, 2019

NOAA weather data

Resources discussed in this post:

This post is just about using public weather data to display a temperature in my windowing environment, but at some point I’d like to use it as a jumping off point for more deeply exploring the available data. It’s really cool how much of this stuff is available as simple text files and the like. Your tax dollars at work, but in a good way.

I use xmonad for window management, and along with it a simple status bar called xmobar.

xmobar offers some monitoring plugins that display various bits of system status and other things. One of them is a weather plugin that can grab temperature and other values from NOAA-supplied weather data. I’ve been using the temperature from a METAR site at Denver International Airport, code KDEN, but I wondered if there was something closer to home available.

I always have the vague sense that there’s a ton of public weather data like this out there, but I don’t have a very good mental map of where it lives and I usually wind up fumbling around until I hit a directory full of text files on some FTP site. The docs for xmobar also aren’t very clear on what the station codes actually reference.

Some notes follow for the next time I’m thinking about this.

xmobar’s weather plugin (source on GitHub) uses decoded METAR station data, available in text files from The path to the site is, at this writing, hardcoded in the plugin.

METAR itself (“Meteorological Aerodrome Reports”) is evidently a standard that’s been around since 1968 in some form. The data looks something like this:

$ curl --silent
2019/02/16 21:48
KDEN 162148Z 36016G27KT 1 1/2SM -SN BKN022 OVC026 M02/M05 A2952 RMK AO2 PK WND 36027/2142 WSHFT 2118 SNB2057 P0000

And NOAA also offers decoded versions, which is what xmobar is parsing:

$ curl --silent
DENVER INTERNATIONAL AIRPORT, CO, United States (KDEN) 39-52N 104-40W 1640M
Feb 16, 2019 - 04:48 PM EST / 2019.02.16 2148 UTC
Wind: from the N (360 degrees) at 18 MPH (16 KT) gusting to 31 MPH (27 KT):0
Visibility: 1 1/2 mile(s):0
Sky conditions: overcast
Weather: light snow
Precipitation last hour: A trace
Temperature: 28 F (-2 C)
Windchill: 15 F (-9 C):1
Dew Point: 23 F (-5 C)
Relative Humidity: 79%
Pressure (altimeter): 29.52 in. Hg (999 hPa)
ob: KDEN 162148Z 36016G27KT 1 1/2SM -SN BKN022 OVC026 M02/M05 A2952 RMK AO2 PK WND 36027/2142 WSHFT 2118 SNB2057 P0000
cycle: 22

In Debian, you can install a package called weather-util which makes for easy searching of the data. Here’s a station at the airport in Longmont:

$ weather KLMO
Searching via station...
[caching result Vance Brand Airport, US]
Current conditions at <UNKNOWN>
Last updated Feb 16, 2019 - 04:35 PM EST / 2019.02.16 2135 UTC
   Temperature: 36.0 F (2.2 C)
   Relative Humidity: 70%
   Wind: from the E (100 degrees) at 3 MPH (3 KT)
   Sky conditions: partly cloudy

Finally, I couldn’t figure out why I was just getting the string “Updating…” instead of a temperature after swapping in KLMO for KDEN, then I realized that you also need to change the station name in the template. Here are the changes I made to my .xmobarrc while writing this post. They also include a tweak to display sky conditions and a slightly different date format.

Tuesday, February 12

reading: astounding

With the full subtitle, it’s Astounding: John W. Campbell, Isaac Asimov, Robert A. Heinlein, L. Ron Hubbard, and the Golden Age of Science Fiction, by Alec Nevala-Lee. I mentioned this one a bit over a year ago. While the author’s preoccupations and tastes aren’t always mine, his blog continued to offer up a lot of fascinating material over the last year, and the book is such an obvious fit for my interests that I both gave and received a copy of the hardcover for Christmas.

Literary and musical biographies have been a disproportionate part of my reading in adulthood, despite the genre usually leaving an unpleasant taste in my mouth. Writers, like musicians, are often difficult figures even when presented charitably, and it seems to be the rare biographer who inhabits that space between character assassination and outright hagiography. I think Nevala-Lee manages in an interesting way here, though it probably helps that I’m going in expecting to actively dislike some of these people and already have complicated feelings about the rest.

Last year in January I tried to summarize my reading for 2017 and wound up concluding:

Because really what I read in 2017, in most of the last several years, was the internet. Not even, in any real sense that registers, individual documents hosted on the network, or the work of authors I can clearly identify. Just the endless scroll.

The internet: A tide of incoherent technical documentation, error logs, seething sociopolitical rage, ideological agitation and condemnation (somewhere between authentic and engineered/rehearsed, on some spectrum it is no longer possible for me to easily parse), clickbait, reaction, comment vitriol, disinformation, machine-generated pseudojournalism, notification spam, marketing, infographical non-info, hot-take product, autoplaying video, and generalized memetic spew.

I could have written the same thing today, I think. Maybe with the difference that I’ve retreated even further from the general stream of clickbait and commentary, and post almost nowhere in public. Which in turn leads to reading less of the stuff that people post about in endless, saturated loops of indignation and competitive meta-analysis.

The general sense that the news is bad and getting worse has only grown stronger, and click-mongering hyperbole aside I think that reflects an underlying reality which is in fact pretty fucking grim. Somehow though, paying the growing hum of the looming abyss less mind has left me, bit by bit, feeling a little more able to deal with the grimness itself.


The 8 best tape decks for home listening

Best Cassette Players | Guide & Reviews | Soundontime

W.S. Merwin, Poet of Life’s Evanescence, Dies at 91 - The New York Times

The origin of the hamburger icon

Supply Chain Security Talk

Choosing tools for continuous integration

Of Git Commits, GitHub, and Gerrit

Gell-Mann amnesia effect - Wikipedia — «The Gell-Mann amnesia effect describes the phenomenon of an expert believing news articles on topics outside of their field of expertise even after acknowledging that articles written in the same publication that are within the expert's field of expertise are error-ridden and full of misunderstanding.»

Re: backports unattended upgrades?

casey/just: 🤖Just a command runner

Introducing the Continuous Delivery Foundation, the new home for Tekton, Jenkins, Jenkins X and Spinnaker | Google Open Source Blog

Welcome to Fabric! — Fabric documentation — «Fabric is a high level Python (2.7, 3.4+) library designed to execute shell commands remotely over SSH, yielding useful Python objects in return»

Taking note: Luhmann's Zettelkasten

List of countries by carbon dioxide emissions - Wikipedia

Winding down my Debian involvement

The Artful Corvid

Sorry, Alexandria Ocasio-Cortez, but “cow farts” aren’t the problem

FaceFacts « ASCII by Jason Scott — «The old saw is that people don’t understand that Facebook doesn’t consider the users their customers – they consider the advertisers their customers. Make no mistake, this is true... but it implies that Facebook takes some sort of benign “let’s keep humming along and use this big herd of moos to our advantage”. But it doesn’t. Facebook actively and constantly changes up the game, makes things more intrusive, couldn’t give less of a shit about your identity, your worth, your culture, your knowledge, your humanity, or even the cohesive maintenance of what makes you you. Facebook couldn’t care less about you than if it was born in your lower intestine and ripped out of you in the middle of the night.»

Accessibility Inspector - Firefox Developer Tools | MDN


Front range radar loop.