David's Mumblings

Useful vi feature

category: Computers and Tech
I discovered a few weeks ago, after years of using vi, that you could do:

:b 


and auto-complete it (with tab) to the buffer with the appropriate file name. For the longest time, I'd been using :buffers (which I'd mapped to \b) to get a numbered list of buffers, and then :b to switch to the given buffer. Being able to use the file name is far more convenient!

It makes me wonder how many other neat tricks vi has hidden away that I will eventually learn (or not). Probably very, very many... ^ TOP

Posted on 06/21/10 at 13:23:14 by dchaley (David Haley)
No comments


Smart store policy

category: General
Whole Foods recently introduced a "party pack", an eight-pack of beer for $10. My guess is that they do it to get rid of the six-packs from which people pulled out a bottle or two. This lets them get rid of lots of no-longer-six packs without having to work too hard. And it lets them have relatively interesting variety packs. It's also a decent enough deal for customers (a six-pack normally costs $8-$12 depending on what kind of beer you're getting). It's a pretty smart solution and lets them keep full six-packs on their shelves, without having to wait to recombine six-packs of the same beer. ^ TOP

Posted on 05/24/10 at 22:19:54 by dchaley (David Haley)
No comments


Money Laundering

category: Humor
While doing the laundry last night, I found two one-dollar bills in the washing machine (very intact, incidentally). Money in the laundering machine. Geddit? Hurr hurr. :-P ^ TOP

Posted on 04/27/10 at 08:49:26 by dchaley (David Haley)
No comments


Math Class Shadow

category: Humor
I think that this is a very funny April Fool's joke: the Math Class Shadow. Certainly one of the more elaborate ones I've seen. :) ^ TOP

Posted on 04/09/10 at 14:59:54 by dchaley (David Haley)
No comments


Funky product name

category: Humor
I just got an ad from Amazon for a so-called "Linear Vortex Nano Arc Foil Shaving System". Woah.

Uh, can I have the version that repolarizes the ion flux beam so that I can modulate the phase variant? ^ TOP

Posted on 04/09/10 at 11:08:57 by dchaley (David Haley)
No comments


Odd APIs

category: Programming
I'm using an API that exposes two functions: (paraphrasing) "get_data" and "get_latest_data". The documentation for "get_data" says that it gets you the data -- ok, fine. But then the documentation for "get_latest_data" says that it gets you the latest data in the system. So why would anybody ever want to use the first function? Both are parametrized by date, so both allow reading historical data. It seems that you might as well call the functions "give_me_old_crappy_data" and "give_me_awesome_data"!

Oh well, hopefully an email to the authors will clear things up. ^ TOP

Posted on 03/08/10 at 13:31:53 by dchaley (David Haley)
No comments


Importance of database indexing

category: Computers and Tech
I'm working on transitioning a school's attendance records from one system to another. To do so, I created a MySQL database to track the various data sets from the old system, in addition to mapping tables to go from the old system's identifiers to the new system's. After some time I eventually needed to write a query that outputs class attendance history for import into the new system. I already knew that database table indexing was very important (at work we use far larger data sets) but I guess I didn't realize that even for relatively small data sets it still mattered so much. Read More → ^ TOP

Posted on 02/13/10 at 22:48:03 by dchaley (David Haley)
1 comment


Nice seatbelt ad

category: General
I thought that this seatbelt ad from Sussex County, UK, was remarkably well-done, and a refreshing change from the ones with splattering blood. ^ TOP

Posted on 02/10/10 at 13:11:56 by dchaley (David Haley)
No comments


Bad Tech Day

category: Computers and Tech
Saturday was one of the worst tech days I've had in a long time. Several things that could have gone wrong went wrong, all at the same time. To start, my laptop died a spectacular and miserable death, overheating up to wazoo and refusing to start. Even when it did start (I propped it up next to an open window giving a roughly freezing temperature breeze onto it) it was running incredibly slowly; apparently something was wrong with the GPU driver. (And then I was getting BSODs.) I took it in on Monday and Systems tells me that indeed something is busted with the GPU and they'll have to replace it (and hence the motherboard).

And if that wasn't enough to ruin my day -- it took me roughly 6 hours to figure out what was happening and try to get files off: I needed those files to get my work done -- I needed to upgrade my file server, and of course that went wrong too. My file server uses two two-disk RAID arrays. One of them decided to drop a disk, for reasons unknown to me. So that took me another hour or two to fix. On the bright side at least I learned more about how the Linux RAID tools work.

Harrumph! In all, I wasted about 8 hours on stupid issues that were completely unrelated to what I actually had to do. Sigh. ^ TOP

Posted on 02/09/10 at 21:19:49 by dchaley (David Haley)
No comments


The Pachelbel Rant

category: Humor
This rant about Pachelbel's Canon in D made me smile. :-) Sort of reminded me of Victor Borge's work. ^ TOP

Posted on 01/20/10 at 11:30:23 by dchaley (David Haley)
No comments