I can know it!
Programming
Fixing Google Contacts CSV Export
Dec 21st
It’s the annual “painstakingly write out a ton of Christmas cards and mail them” time of the year again, however this year I’ve set out (and succeeded) to make Erin’s life a little easier.
You see, I found this fantastic article that described how one could simply export a Google contacts list to CSV and use the Avery Designer Pro (I’m using the mac version) to map the columns from the export to generate the labels. This sounded incredibly easy, and so I set out to try to simplify our Christmas card mailing process…
After blindly following the guide (see above), I quickly realized there was a huge issue – Google does not do anything to ensure the resulting CSV file is formatted properly. While there are many, many columns in the CSV export (including individual fields for the various components of an address), Google has taken the easy way out and simply filled in the “formatted” address column along with all of the line breaks occurring from typing the address in. The end result was the Avery software printing out 2 (or more) separate labels for every contact, with their address being split across them. So, I decided to fix the CSV file.
Solving a Permutations problem
Apr 19th
The wife and I have been having problems settling on baby names for our first child (coming any day now!), so I decided that I’d see if I couldn’t help out with a simple web app that would let us put in the names we are considering and spit out all of the possible permutations. After performing a modicum of research in to combination and permutation algorithms for both javascript and ruby (I decided the fastest way to get this done was with rails), I quickly realized that my problem wasn’t as simple as most of these algorithms made it out to be. See, I didn’t need all of the permutations of an array of size n, as that represented all of the names and not just the few that usually make up someones first and middle name(s). What I needed was an algorithm that listed all of the permutations of an array for a given resulting array size without repetition. I remember finding a particular example that generated permutations in to power-sets, which I could have then just filtered out anything that didn’t match the power-set the user specified, however I can’t recall why that approach didn’t work out.
More >
Syntax Highlighter Test
Feb 22nd
I thought I’d test out this syntax highlighter by showing an example of creating a secure download site in PHP…