Yesterday and today I have been mostly “data munging” – the process of transforming data from one format to another slightly different format.
As it’s all for a one off data import, I have been mostly using Vim to do the editing.
And as most of the data is around 200 lines or so I’ve resorted to what I call “Daley Thompson’s Decathlon” style editing. This is where you repeatedly hammer the ‘n’ (for next match) key and the ‘.’ (for repeat last action) key, just as if you were propelling Daley himself along your screen.
Normally I don’t like to do that style of editing, preferring instead to put together some macro, or a search and replace string involving regexes, but in this case I realised that by the time I’d figured out the clever way of doing it, I could have finished it by hammering away at the keyboard really quickly.
It reminded me that now and again, cleverest isn’t best.