One Aging Geek

Friday, June 30, 2006

Over the edge into total chaos

A couple of months ago, Mrs. Geek and I uprooted ourselves from our home of 22 years to move about three miles. The new (to us) place is only 11 years old, we were the first owners of the old place so ... do the math.

The new place needs lots of work. With Mrs. Geek, it's just a given that every wall and ceiling in the place will get painted. And she works like a dog at doing it. Since moving in she's already done everything upstairs except the master suite. Downstairs, the study ceiling and walls have been done. Last weekend we pitched in together and did the main downstairs ceiling. The new place is an "open floor plan" so the entire downstairs except for the study is one connected ceiling. Since then she's done the dining room and foyer areas. Along with the painting has been lots of cleaning and patching the seemingly thousands of nail and screw holes the previous owners made.

So the upshot is that the household has been pretty unsettled ever since moving in. Minimal unpacking in rooms not yet painted, ladders, drop cloths and tools everywhere. That sort of thing. The carpet from the study and dining room has been ripped out so those rooms are bare concrete. The study is jam packed with displaced furniture plus the wood and associated paraphenalia for the future wood floors.

But this weekend it's going to go from unsettled over to total chaos. The major things we're doing are to replace the kitchen cabinets and countertops and to replace all the carpet and tile downstairs with wood and nicer tile or stone.

The new cabinets are due to arrive on July 6th. Between now and then I'll be taking down the existing cabinets, a DIY project that saves me about 10% of the cost of new cabinets. Then we'll have someone come in to remove the existing tile in the foyer, kitchen, and breakfast areas. Some time within a week or so after the delivery of the new cabinets the installer for those will come do his job. Then will come the new tile floor, new granite counters, new backsplashes, new sink and faucet, new dishwasher, etc. Mixed in there while the kitchen is a gutted shell will be some painting and rearranging of wiring.

Oh, and there's a downstairs powder room that will also be stripped to bare walls and re-done. Tile floor to replace ugly vinyl stick-downs, remove ugly wallpaper, paint, new sink, and new toilet.

So after the tear out we won't have a functioning kitchen or any source of running water downstairs. And 90% of the dishes will be in boxes. And the coffee pot will live in an upstairs bathroom.

I have to keep reminding myself how good it will look.

Tuesday, June 27, 2006


So right after I was making a deal about my scripting skills I noticed that I hadn't gotten a TAL episode when expected.

I had been pulling files from the Complete Archive page. For some reason episodes are posted there a few days later than they are on the current year archive page.

So since I was feeling all pumped up I decided to change over the script to use the current year archive page. The links on the page (either the complete or the yearly) point to M3U playlist files. But between the last time I fiddled with this script and this time, the contents of the playlist has changed. Or I didn't look very closely before.

For some reason the playlist files each contain four entries. That would normally be four "tracks". So I guessed that they were now posting the episodes in four parts. Since the show is usually an intro followed by three "acts" that wasn't much of a surprise. I twiddled up the script a bit to read all four "parts" and put them in a directory where they'd eventually find their way onto my MP3 player.

To my surprise I didn't get four parts, I got four repetitions of the entire show.

My only guess at this point is based on each of the entries in the playlist having a different port. My guess is that this is some kind of poor man's load balancer. So I'm picking one at random. The script to get the archive page, find the first 10 playlist files referenced, extract the episode number, match the episode numbers against a log file that prevents duplicate downloads, fetch the contents of the playlist file and select a random entry from it is five lines of fairly dense bash script. The script that then fetches the episode, figures out where to store it, makes the directory if needed is longer because it isn't just a couple of pipelines, it's 25 lines and still has all the code to loop thru multiple parts. Without the looping and the directory creating logic it could be boiled down to a single call to "curl".

Learning to think in pipelines: priceless

Monday, June 26, 2006

Much to do about not much

Getting stuck on a death march has kept my blog reading to ... well ... none... for about the last three weeks. So I mostly missed the uproar about This American Life on BoingBoing (and elsewhere but summarized nicely there).

It's been easily possible to automate the downloading of TAL episodes since ... well probably since the first time they were posted online.

For a long time they were posted as Real Audio which isn't quite so convenient for us MP3/OGG/WMA device owners. But even that could be converted to MP3 with a few common tools and a short bit of script.

Now that the files are in MP3, it's dead easy to grab the "complete archive page", find the first show listed, read the M3U playlist file to get the MP3 file link and fetch the file. So dead easy that I'll leave it as an exercise for the reader. It took me just over 40 lines of bash script including managing a log of previously downloaded episodes to prevent repeats.