## Sunday, February 26, 2012

### Weddings with Awk, Latex and Google Docs

Hey guys, I'm getting married! Pretty sweet, right?

Like any good software developer, I am always trying to save myself boring work with scripts and tools. Sure it may end up taking more time, but it's more fun.

Anyway, I thought I'd share a little bit of our wedding workflow, since I think it has been pretty effective. It all starts off with a few Google docs. These documents are all shared, so both my fiance and I can update them at any point during the day. Those documents include a text file with ideas and tasks to be completed, along with a spreadsheet of the gifts we've received, who gave them and whether or not we'd sent them a thank-you. We don't want to forget anyone, nor forget what they gave!

But the most useful document has been a spreadsheet containing the guest list. In the row for each name we filled in their addresses as we received them along with a Y/N column indicating whether or not that person would have a 'plus one.' We were careful to put each piece of the address (street, city, state, ...) into its own column, which is helpful for the script I wrote later. We also had two Y/N columns indicating whether that person had been sent a save-the-date and an invitation.

So that's it. Nothing particularly clever, but I kind of wanted to share my experiences. I think that overall we've saved a ton of time generating the labels this way. Certainly vs. writing them by hand, but even vs. using Word to create the labels.

1. Congratulations!!! I hope you spend lots of years full of joy and happy memories together!

I really like the idea. I wish we could think of something like this when we are getting married :(

By the way, would you like to share your script? :) Maybe I could use it for a different occasion :)

2. Thanks!

Yes, I'll reprint the script below. You may not find it that enlightening because there are a bunch of references to columns in my wedding guest list (those are the things lik $18,$20, etc.).

Hope this is useful!

BEGIN { FS = ",";
print "\\documentclass{letter}";
# print "\\SetLabel{2.75in}{1in}{0.5in}{0.19in}{0.35in}{3}{10}"
print "\\makelabels";
print "\\FirstLabel{1}{1}";
print "\\begin{document}";
print "\\startlabels";
}

$3 ~ /.+/ &&$10 ~ /.+/ && $18 !~ /Y/ { printf "\\mlabel{}{\\rmfamily\\normalsize "; printf "%s",$10;
if ( $3 ~ /Y/ ) { printf " and Guest"; } printf "\\\\" printf "%s",$11;
if ( $12 ~ /.+/ ) { printf "\\\\%s",$12; # Apt
}
printf "\\\\";
printf "%s, %s %s", $13,$14,$15; if ($16 ~ /.+/ ) {
printf "\\\\%s",\$16;
}
printf "}\n";
}
END {
print "\\end{document}";
}

3. A lot of toss pads that was given as a blessing will in every case please the provider each time the person visits the home of the beneficiary and sees the toss pads being used. bamse af roser