Hacker's Diary

A rough account of I did with emacs recently.

August 31
Another day in London. Argh.

August 30
Night at the movies. Hacking, nil. High Fidelity is an excellent movie, but the book is better.

August 29
Tuesday? What the hell happened to Tuesday?

August 28
Oh the humanity. I made the classic libc Y2K error in the folder hacker - years are $yr + 1900, not two-digit years. Doh. Fortunately I'd only made the error in the folder-naming code, so that's not too big a deal. I still haven't done any more with the threading, and it occurs to me I could do some smart From: line mangling as well.

Bob gave me his old Palm III since he's gotten a Palm V and my own Pilot is still in the Dead Zone. I started reinstalling PilotManager since I'd nuked my installation of it for some unknown reason.

Set up the twisted-pair network at home, which required some DHCP tweakery on Gonzo and also a new installation of Linuxconf since the version I had installed was expecting to find dhcpd's leases file in /etc rather than /var/state. Still, it all seems to be happy now and it makes moving stuff around a lot easier. The Mac seemed happy enough with the 10Mbit connection, too. This means I've now got a spare Mac network card and a spare PC network card, both 10base2. Oh, and I upgraded Gonzo to test7 while I was at it.

August 27
Did a little more work on sorting out the DSPsrv mail archives, mostly escaping "From " lines to stop the folder frobnicator from breaking. Seems like Mailman uses its own version of mbox format to store messages. Losers.

August 26
Went back to Maplin with my networking kit to get a set with all the right parts in it. The guy in the shop discovered they had another kit upstairs with exactly the same problem - 5V PSU for a 3.3V hub. He snarfed a PSU and hub from another kit by the same manufacturer instead. So now I've got my home speedy network. Except that I need to dismantle Gonzo again to put in the new network card.

Put the old, trashed DSPsrv disk into the 486 and set about investigating disk recovery options. Turns out that most of the missing stuff is in lost+found, with a small amount of corruption (one email message in a 2000-message folder, for example) so I've not had to resort to reading inodes with a disk editor... I snagged the whole directory and spent a few hours examining and renaming the files therein.

August 25
Finally set about getting the DVD player working by hauling my copy of the livid codebase off Gonzo and onto Klortho. After a little poking and prodding, I got it working. It's doing about 11-14 fps depending on prevailing wind, which isn't quite good enough, alas. I have a vague hankering to try hacking DGA support into it, since I haven't a clue about DGA and this'd be a good way to find out.

Found the following while rooting through old DSPsrv mail:

On 3/4/1994, Waider wrote:
My watch crashed this morning - low power. Lost all my phone numbers and I don't have complete backups.

My disk drives for fozzie don't fit into the cornflakes box I kept for them.

Fozzie & Gonzo aren't talking to each other since I cased Gonzo(II)
Yeah yeah. I crashed my watch. I've also managed to crash a mobile phone. Just call me the walking glitch. Incidentally, the mails were in a monster .PST ("Personal Folders") file from an old copy of Microsoft Mail. Outlook 2K opened it without asking any questions, which is impressive backward compatibility, except that the file was supposed to be password-locked... And you simply can't export anything useful from Outlook, certainly not without heartache. The most usable outbound format is CSV, and that doesn't, for some reason, allow you to export the Date header. Uhhhhh..

August 24
Spent the day in London on business. By "day" I mean I got out of bed at 5:30am and didn't get back to my humble abode until 22:00 or thereabouts. Urgh.

August 23
Tried to sort out some apparently proxy-related problems with work today. Apparently some proxies will cache cookied pages and dynamically generated pages with no regard for the implications of this. Bad proxy! No cookie!

Dermot's working on a modified version of collate at the moment and running into regexp problems.
"Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now they have two problems."
-- jwz.
I sent him a possible solution using HTML::Parser, which has gotten far more hairy^Wpowerful since I last used it.

Upgraded Klortho to 2.4.0-test6, which I thought I'd done already. Kids, don't forget to drop the --dry-run flag the second time you run patch. Of course, now I'll have to kick VMware until it works again.

Prodded the VT100 manual some. It's amusing in places - it notes that your key repeat rate may be limited by your baud rate, and in the escape codes section, it starts by telling you that ESC [ is the "Control Sequence Initiator" and then goes on to give ESC # 6 as an example. Er, where's the [ gone? It brings back some memories, too. Like sticking Terminal Reset characters into text files at random to mess up anyone who tried to casually browse them.

Snagged a DVD drive off a laptop marked "Floater" in the office to use instead of the CD drive I had. I'll need to reboot into a kernel with UDF support before I know if I'll be able to watch DVDs, but at least OMS didn't blow up on attempting to load, which is what it does on Gonzo - I'm guessing the K6 may well be the problem there.

Found a stupid STUPID bug in the mail archive sorting code that meant it noticed duplicates but filed 'em anyway. DOH.

August 22
Modified jmatrix to be a little more modular, so it's easier to see how to add it to a page. Whether you'd want to or not is another matter. I should see if it's possible to preload the images in a cleaner way, too - when I started hacking this, I tried loading a composite of all the glyphs, then creating layers and cropping them. Netscape got a bit pissy about having so many layers, though.

Modified the script I use to update my site to insert a list of the most recently modified files on the front page. It's kinda gross:
perl -p -i -e "s|-- UPDATES -->.*?</td>|-- UPDATES -->`(echo \"<b>Recent Updates:</b><br>\"; find . -name \"*.html\" -mtime -5 | grep -v misc/avantgo | tail +2 | head -5 | sed 's/\.\/\(.*\)$/<a href=\"\1\"><tt>\1<\/tt><\/a><br>/')|perl -p -e 's/\n//'`</td>|" index.html
I also modified the script I use for thumbnailing after giving it the caption instead of the filename to rename to for the 10th time. It now figures that if you put spaces in the filename, you meant it to be the caption. There's gotta be an easier way, mind you.

August 21
Discovered yet more bogosity in the headers of the old DSP archives, so I modified the undigestifying program to cope. Next thing I need to do is get jwz's threading algorithm into Perl, and make use of it.

Made snorq link to the originating page for debug purposes, or something.

Whee! Gratuituous abuse of technology time! I'm currently hacking away on Klortho, which is hooked via serial port/PPP to Gonzo and thusly to the 'net; the Ethernet port is sprouting a crossover cable which is plugged into the back of a mess of hardware on the table - essentially a 486DX2/66 with a monochrome 12" monitor. The mess on the table is installing Red Hat 6.2 from a loop-mounted, HTTP-shared ISO image on Klortho. Claims it'll be finished in another 2 hours 47 for some reason... SrvMon.pl says I'm getting about 6 of the 10Mbits I'd expect from the Ethernet link.

August 20
Consolidated the Perl toys I had on Gonzo with Klortho's pile of junk. I really need to do something about disparate home directories. I've seen a reasonable hack that essentially does a directory sync between laptop and server, and when the server's available, NFS mounts the server directory over the laptop directory or some such oddness.

Had a look at getting my SMS toy working with e-merge, Eircell's excuse for a WAP/Mobile portal. It's a load of rubbish, but I like the convenience of sending SMS messages from the command line. After about twenty minutes I'd figured out the necessary changes. I'm thinking of integrating this into the DSP directory - something like "click here to send SMS to...". The main problem with this being that the two SMS portals are network-religious - Dot On-Line sends only to DigiFone handsets, and e-merge only to Eircell. It's like they're trying to get folk to buy one brand or another via peer pressure...

Remade my patch for Mail::Folder. Discovered something else broken since I patched it originally - looks like maybe an API change in one of the modules it uses. Gah. That's all fixed now, though, so grab & patch.

August 19
Started rebuilding my old 486 with the intention of giving it to a cousin as a Win95 box. Discovered that it had Corel Linux on board from when I reviewed it back in my previous job, and it was quite happy to boot it up. This amused me no end, for some reason. I decided to try out Red Hat 6.2 on it - I know, 7.0 is only around the corner, but I have a 6.2 ISO living on Klortho and this seemed like an ideal time to sling it over to Gonzo and do a network install. It'll finish transferring in another, oh, 5 hours or so. Goddamn serial networking...

Did a little shopping today (like I need more hardware...); I bought a 30GB drive at Peats and a complete two-PC networking pack made by LinkSys from Maplin. The former is destined for Gonzo, the latter intended to provide me with a 10/100MB network rather than the straggling thinnet/serial cable mishmash I'm using at present. Alas, the latter came with the wrong power supply, and by the time I'd discovered this and verified that I didn't have anything compatible lying around, the shop was closed. Grr. In the meantime I'd upgraded Gonzo to 2.4.0-test6 and built the necessary drivers for the LinkSys card. Oh well. It'll be all set for installation, at least.

Grabbed the VT100 test program off some random website and discovered it was last modified in 1995 or something so it won't compile without an amount of kicking. Also grabbed a VT100 manual off some other site. I'm taking this phosphor hack FAR too seriously. Much as I don't like the "Not Written Here" school of coding, I'm beginning to think the only way to do this right is to do it myself. Doom awaits, I'm sure. Oh, and the idea of using a YACC grammar to do the job appeals to me, horrifically enough.

August 18
More mods to Chris's code. It can now remove V2 tags from files as well as V1 tags. Next step is to get it to write V2 tags. Also need to provide V2.2 -> V2.3 tag conversions and CDDB genre conversions.

Fixed a bug in BBDB's VM integration, to do with caching. An odd one that I didn't quite understand, but it's fixed now.

August 17
Finally started doing the Right Thing with the mp3 hack - I've modified Chris Nandor's MP3::Info module to handle ID3v2.2, which turned out to be easier than I expected. What I need to do with it now is add in write capability for ID3v2.3 tags and remove capability for anything else so I can retag all my files properly.

August 16th
Tweaked the APM toy to differentiate between charging and just running on mains. Why, I don't know; completeness, maybe.

Finished moving the mailboxes around. There's still a little stupidity there, but nothing too serious. For an encore, I reconfigured sendmail on Spike. I really, really, really need to finish off, or at least vastly improve on, the m4mailconf module for Linuxconf.

Started looking at integrating whatever of gnus-bbdb.el I haven't already got into bbdb-gnus.el, per a user request. Diligent, no?

Poked at phosphor some more trying to figure out what's actually wrong with the hacked VT100 emulation. I may just rip out what I've coded and re-port it from minicom again, or maybe I'll grab that VT100 test kit I stumbled across and see where it's failing.

August 15
Our ISDN line at work is less than 100% perfect, and I finally got fed up of manually restarting the thing every coupla days when it jams for whatever reason, so I wrote a little monitoring script to repeatedly ping the far end of the connection and do a drop-and-restart whenever the pings stop. Crude, but effective. Well, except that I need to make it less picky about when it thinks the line is down, because when the line gets loaded ping-times go through the roof. Or I could learn about QOS settings and give pings maximum priority.

Spent some time moving some mailboxes around. What a drag. Create new mailbox, create .forward, fetch mail from old mailbox, change settings to new mailbox. Lather, rinse, repeat.

Evening hackery is somewhat patchy this week since I'm trying to pack my apartment into boxes to schlep out to my new digs in Cabinteely. I did, however, go hacking at phosphor some more and it now kinda runs cmatrix, which is rather terrifying. Remind me why I was doing this again?

August 14
Sent the iPivot box back to the Intel guys, since I'm done playing with it. Nothing else of note to report, although I did investigate some build problems with BBDB.

August 13
Got a phone call early today from one of the guys who was in the pub last night, and he'd basically persuaded the bar manager that I should get in touch about managing their website. If that isn't knowing your local bar too well, I don't know what is...

I went back at phosphor and hacked in a few more things, including making it whine and dump if an unimplemented (i.e. I was too lazy to hack it) sequence is used; this prompted me to add clreos and attribute support. Well, bold text. Well, text that's a different colour. I should really generate a bold font and use that.

August 12
Mucked around with last night's phosphor hack a little before meeting up for the usual Saturday lunch, which turned into the usual Saturday beer, which turned into the not-so-usual Saturday fondue party/sing-song. Hic.

August 11
Slow day... prodded the iPivot box some more, and played around with a few perl scripts. Nothing of note, though. Blame it on the beer again.

Owning a laptop is all sorts of badness for me. I've gotten into the habit of setting up at my desk at work with the seat tipped back as far as it'll go and the laptop on, well, top of my lap and my feet up on the server under the desk. And at home I've tried flopping around in all manner of postures, all facilitated by the fact that the laptop's a nice, convenient size/weight and doesn't seem to mind being slung around the place. So right now I'm sitting cross-legged on a stack of cushions with my back to the couch and the laptop resting between my legs with the screen over my feet. Surprisingly comfortable. AjD says the radiation from the laptop is probably making me impotent.

Had a chat with JoeV earlier about browsers, among other things. He thinks that Netscape/Mozilla is pretty much doomed, and that Mnemonic is still a valid contender, once the current development fuzz gets sorted. I dunno. I'm still using Netscape.

I started poking at the mail folder processor again, and discovered that not only did Klortho not have Mail::Folder installed, but the author still hasn't fixed it to work with the newer Perls, so I have to go back to the version on Gonzo and see what I did to it to make it compile. GRR.

Logged onto #dnalounge for a while: (some text elided)
        <jwz>    hey, why don't you build vt100 emulation into phosphor?
        <jwz>    that would rule.
        <waider> vt100 emulation? You mean like the escape codes
                       that allow you to do bold text, cursor position, etc? 
        <jwz>    yeah
        <jwz>    people really want to run "top" on it
        <waider> wow. that's a bit twisted.
Twisted. Indeed. So I wandered off and found a suitably monolithic VT100 implementation in the source for minicom, and set about abusing it. At about 5am I had enough of it kicked into shape to run top, at which point I decided I'd be far better off getting some sleep.

August 10th
The iPivot guys called today. Poked at the iPivot box briefly and got it running - loose chips, apparently. I was very impressed with how quickly we got it set up - generate key, generate cert, assign IP address, and whoosh! SSL. Good stuff. Now to try loading it a little. Went to Phil's web guide to grab the load tool I'd seen there, and realised that Phil is a tcl zealot. See, he gives the following justification for creating the thing:
Why write Yet Another Simple Tool? We wanted a tool that didn't require someone to compile (or port) a C program, that doesn't require Perl and Perl libraries, and one that works with AOLserver, since that's what we use around here.
Eh. It does not, indeed, require me to install Perl libraries. It does, however, require me to install AOLserver and Phil's AOLserver utilities. And since I probably have the required Perl modules already in place for some other random load-generating tool, I don't think I'll be using Traffic Jamme. Cute name, though.

August 9
Ran the website through collate on prompting from a friend that my site was "full of broken links" and fixed the resulting mess. Some of the remaining brokenness is due to javascript stuff, some due to the output from snorq which doesn't normalize relative links in the pages it downloads. Hmm. Maybe it should. While looking at this, I modified snorq to clean up the tail end of Slashdot properly, and also to add a date, time and hostname stamp at the top of the page. Started on the CGIification of it as well.

Had a look at Mojo Nation's site, downloaded the stuff, but didn't install it. Not yet, anyway. Looks like an interesting proposition.

The crawling horror now runs on IE 5.5 - 5.5 since it makes use of the fact that 5.5's in-line frames are stackable. I have no idea what it'll do on older versions of IE, although Cliffy says it killed his machine when he tried it on IE 4.0. Jeez.

Had another peek at sorting out the DSPsrv mail archives going back to year dot (1994, as far as DSPsrv is concerned). I now have a script that converts a majordomo digest into a From_ mailbox, which I can then feed to the horror that I'm building to do the rest of the sorting and filtering.

Finally tried out the iPivot box and discovered it's suffering some sort of fault that's not documented in the manual. Oh well. The guys are calling around tomorrow to talk to me about it, so maybe they'll be able to show me what's up.

August 8
Been getting some amusing reactions to Sunday's hack, along the lines of "That is truly bent." and "Waider, you are SUCH a geek" and "You're a sick little monkey" (the last after I mulled the possibility of adding a second layer to provide double-buffering). I've been poking at the Microsoft site intermittently to see what I'll have to do get it to work on IE.

Some of the work I did in Norway has mysteriously stopped working. Faced with the possibility of another short-notice trip to Oslo, I did a little quick thinking and came up with a workaround. After all, the stuff in Norway was supposed to be a transient fix, so a workaround for a workaround is acceptable until the great juggernaut that is organized development manages to get itself up to speed.

The iPivot box has finally turned up. It's a lot bigger than I expected - about the size of a Cisco 3600-series or thereabouts. I can't for the life of me figure out why, but then I haven't taken it out of the box yet, since I'm busy firefighting the above code, and also since I'm short of kettle leads and patch cables.

Finished up the day with a site update for Micromail; spent an hour tracking a bug that wasn't really there, after which I resolved yet again to rewrite the crawling horror that manages the site update. Yeah. Right.

August 7
Very little hacking. Spent some time getting 2.4.0-test5 up and running on Gonzo and Klortho; it appears to cure the PPP problem I was having. Interestingly enough, 2.4.0 ppp will not, apparently, talk to 2.2.17 ppp. Go figure.

August 6
See, this is the sort of thing that happens when I get distracted: I go abuse some poor innocent browser. For a more amusing version, check the alternative index page.

I decided I couldn't possibly top this and spent the rest of the day fiddling with my website.

August 5
Discovered 3dwm while snuffling around freshmeat. Looks nice, but suffers from that most horrific of free software traits, vapourware. It's not quite what I was waffling about in my dream computer thing either, but hey.

Finally dropped my busted palm pilot back to Dixon's for repairs. They gotta send it off to Mastercare, and the guy told me to call in two weeks to find out what they're doing - repair or replace. It looks like it should be a repair (there's a crack across the glass, and the touchscreen no longer works) but someone's told me that the screen is the single most expensive part of the kit to repair, so they may well punt and replace.

Fixed what I thought was a "can't happen" bug in BBDB in the migration code. Some bugs are easy.

Added the DNA Lounge's log to snorq. I should probably toss all my daily reading in there, make it a CGI script that updates when I hit it rather than on cron job, and use it as my lunchtime browsing page instead of the current trip around the bookmarks. In the process I discovered that Klortho's not set up to actually run snorq, so I grabbed the necessary modules. I hate moving machines, stuff like this happens for months afterward.

Went hacking at the magic MP3 renaming program again, and found that there's a third, incompatible, MP3 tag manager for Perl. Why can't people just share this work? Better still, why can't someone just write a module to interface to id3lib and be done with it? Anyway, I contributed further to the noise by modifying this new module to handle the older v2.2 format that a few products insist on producing. I only wanna read 'em; I'll retag in a nice kosher ID3v2.3 format, or better. I should probably have hacked Chris Nandor's MP3::Info module rather than the rather clumsily-named MP3::ID3v2Tag module, but that's hindsight for you, or something. Oh yeah. And the latter has code-generating code. ARGH. Anyway. mp3name.pl is slowly but surely turning into a monster. I'm not sure if I should be proud or ashamed. Latest addition is the ability to spew out CDDB-format files so that I can feed the resulting mess to Gronk, more or less.

August 4
Whoop. Had an encounter with mister beer and his friends last night, so I'm running a little slow this morning. Just noticed a bug in the share monitor, but it's cosmetic only. Nothing a little sprintf won't fix. Added an indicator to tell me which site it's coming from, too. Why, I do not know.

Poked at the proxy autoconfig some more. It's still not working, dammit. I'm thinking maybe I'll just install squid locally and get that to do the figurin'. Or generate the proxy file from a CGI-script.

Intel guy has told me the iPivot box should be here today. Not seen it yet, though...

I've been playing with Remembrance Agent again. I can think of a few improvements I'd like to make, but I'm trying to resist the urge to play with something else. After all, the CDDB source is still sitting in my tmp directory waiting to be unwrapped. Anyway. It should, for example, not suggest the document I'm working on as a relevant document. It'd also be nice to bolt it into Squid to make a personalised search engine; this kinda ties into my Web Agent idea. Or bolt it into Netscape's cache. It seems to log the scores purely for research rather than to assist feedback, too, which strikes me as wrong. And it'd be nice to have a "never show me this document again" option. And the "-e" flag on raindex could do with being smarter. And live indexing would be good. Also cumulative/incremental indexing, although maybe it does that already - I haven't checked. Oh, and it'd be nice if when I'm writing HTML like this if it could, rather than pop up associated doco, generate links to the doco around the last word I typed. That would be FAR too cool.

August 3
Finally hauled my website onto Klortho (the laptop). The TCP stall I'm experiencing with Linux at the moment only appears to happen in one direction; fetching multi-meg files from Gonzo to Klortho runs at a flawless 10.95 K/sec, but trying to push anything down the pipe in a hurry (such as, for example, a CVS update) blocks the entire stack. Worse still, I don't know who I should complain to about this; it's not like there's a bugs@linux.org address! So much for Linux's world of support. Anyway, the problem seems to go away with the 2.4 kernels, so maybe once there's an official 2.4 release I'll upgrade everything. I'm currently tweaking all the web pages to use a stylesheet, something I discovered on my recent jaunt to Norway. Stylesheets are a neat idea, if somewhat haphazardly implemented.

My proxy autoconfig still isn't working correctly. I'd put a switch into it that checks if I'm on the office LAN or the home LAN (using myIpAddress()), and sets the proxy accordingly. Alas, it seems to fail every time. I must be missing something very obvious here.

Discovered that the Yahoo ticker for the share price wasn't updating today, so I built in a fallback to ask StockLink instead. This runs a little delayed by comparison to Yahoo's ticker, but it's still useful. Backed the timer off to 5-minute intervals, too.

August 2
Finally got hold of the iPivot guy; he's checking to see if they have any spare demo models he can send me. Also finally relented and set up a list for the DSPs working in the area to coordinate lunch. Abuse of Technology!

Dug the PowerEdge out from under the desk it was hiding beneath in the sales office so I can set it up for the SSL box. I'll prolly put apache/SSL on it as a comparison.

Spent a little time setting up xmame to play my all-time favourite arcade game, Twin Cobra. I have a deep, irrational desire to own a stand-up cab for this game.

Tweaked the share monitor some more to have an indicator telling me if the price has gone up or down since it last checked, and also to display a bunch of queries if it can't get the page (like when my machine's offline). Also added Tk::CmdLine so I can set the colours from the command line like I do with the rest of my FVWM toolbar stuff. I was so pleased that I made the same mod to the APM gadget.

This is why I get so far behind in my offline work: I've just seen that the FreeDB blokes have handed out their current CD list, and I think it'd be fun to have. So I've grabbed their source code from the site. OH boy. New toy. Decided after a few hours that having 90% of my 4GB Linux partition filled because of the amount of junk I keep downloading and not working on that I'd nuke a bunch of other stuff I've not touched, and then did some more work on the magical mp3 renaming program.

August 1
Bossman was in a happy fluster this morning about the share price, so I spent ten minutes adapting my APM toy to monitor the share price and display it in a window suitable for FVWM2. That makes three monitors I've written based on approximately the same code; it's time to start thinking about modularising it.

Some of the BBDB stuff has been sitting in my mailbox for far too long, so I started merging things in. About half a dozen random emails and patches, going back to at least May. Some things are still sitting on the 'uncooked' pile, mind you. BBDB<->Pilot integration is a biggie; everyone wants it, but no-one seems to be really sure how to do it. Every coupla weeks there's a flurry of activity on the bbdb-info list, which has thus far produced two or three chunks of perl and at least three bbdb-pilot.el files. My own work on this is hampered by my breaking my pilot recently and not getting it repaired just yet. There's also the long-running issue of parsing zip codes and phone numbers vs. just leaving them as plain text, with solid arguments on both sides (aside from jwz's suggestion that we just all get green cards and quit whining!). I'm discounting anything that mentions cleaning up the code - old habits die hard, and this one I learned a long, long time ago. You break more things with cleanups than you fix, and the fixes generally only benefit the coders. Code cleanups should be incidental, not primary, and anything that's for the coder's benefit at the expense of the user is a Bad Thing.

Today's day job work is essentially to see if I can wangle an iPivot SSL box out of the nice folk at Intel for evaluation. Specwise, it looks good, and I have a spare PowerEdge lying around that'll allow me to do some pretty good testing. Must dig up some load-testing software, too; I seem to recall seeing some at Ars Digita when I was wandering around Phil's web guide.

current month | next month

A little Perl will fix this.